From 744ed6bff8a3ad799f45f3aa70307905081370db Mon Sep 17 00:00:00 2001 From: Diego Scataglini Date: Tue, 30 Jul 2024 14:42:08 -0400 Subject: [PATCH] should mark js code as html_safe --- app/helpers/opal_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/opal_helper.rb b/app/helpers/opal_helper.rb index 029c8d1..0842780 100644 --- a/app/helpers/opal_helper.rb +++ b/app/helpers/opal_helper.rb @@ -11,7 +11,7 @@ def opal_tag(opal_code_or_options = nil, html_options = {}, &block) compiler = Opal::Compiler.new(opal_code_or_options, compiler_options) js_code = compiler.compile javascript_tag html_options do - js_code + js_code.html_safe end end