Method: Formular::HtmlEscape#html_escape_once

Defined in:
lib/formular/html_escape.rb

#html_escape_once(string) ⇒ Object

A utility method for escaping HTML without affecting existing escaped entities.



15
16
17
# File 'lib/formular/html_escape.rb', line 15

def html_escape_once(string)
  string.to_s.gsub(HTML_ESCAPE_ONCE_REGEXP, HTML_ESCAPE)
end