Class: HoboFields::MarkdownString

Inherits:
RawMarkdownString show all
Includes:
SanitizeHtml
Defined in:
lib/hobo_fields/markdown_string.rb

Constant Summary

Constants included from SanitizeHtml

SanitizeHtml::PERMITTED_ATTRIBUTES, SanitizeHtml::PERMITTED_TAGS

Constants inherited from Text

Text::COLUMN_TYPE, Text::HTML_ESCAPE

Instance Method Summary collapse

Methods included from SanitizeHtml

sanitize

Instance Method Details

#to_html(xmldoctype = true) ⇒ Object



8
9
10
# File 'lib/hobo_fields/markdown_string.rb', line 8

def to_html(xmldoctype = true)
  blank? ? "" : HoboFields::SanitizeHtml.sanitize(BlueCloth.new(self).to_html)
end