method
to_plain_text
v7.1.3.2 -
Show latest stable
- Class:
ActionText::Content
to_plain_text()public
Returns the content as plain text with all HTML tags removed.
content = ActionText::Content.new("<h1>Funny times!</h1>") content.to_plain_text # => "Funny times!"