Skip to content

Commit

Permalink
Avoid using escape_html option
Browse files Browse the repository at this point in the history
  • Loading branch information
k0kubun committed Feb 15, 2023
1 parent 5cfdffb commit 3725ebb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion run-benchmarks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def init_compiled_benches
def run_erb; #{ERB.new(@erb_code).src}; end
def run_temple_erb; #{Temple::ERB::Engine.new.call(@erb_code)}; end
def run_erubi; #{Erubi::Engine.new(@erb_code).src}; end
def run_haml; #{Haml::Engine.new(escape_html: false, escape_attrs: false).call(@haml_code)}; end
def run_haml; #{Haml::Engine.new(escape_attrs: false).call(@haml_code)}; end
def run_slim; #{Slim::Engine.new.call(@slim_code)}; end
}

Expand Down
6 changes: 3 additions & 3 deletions view.haml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
%meta{ charset: "utf-8" }
%meta{ name: "description", content: "This is an example of a meta description." }
%body
%h1= header
%h1!= header
- unless item.empty?
%ul
- for i in item
- if i[:current]
%li
%strong= i[:name]
%strong!= i[:name]
- else
%li
%a{:href => i[:url]}= i[:name]
%a{:href => i[:url]}!= i[:name]
- else
%p The list is empty.

0 comments on commit 3725ebb

Please sign in to comment.