class String

Constants

BLANK_RE

Public Instance Methods

blank?() click to toggle source
# File lib/swee/support.rb, line 66
def blank?
  BLANK_RE === self
end
html_safe() click to toggle source
# File lib/swee/support.rb, line 70
def html_safe
  self.gsub /[&"'><]/, { '&' => '&amp;',  '>' => '&gt;',   '<' => '&lt;', '"' => '&quot;', "'" => '&#39;' }
end