class Minidown::HtmlElement

Attributes

name[R]

Public Class Methods

new(doc, content, name) click to toggle source
Calls superclass method Minidown::Element::new
# File lib/minidown/elements/html_element.rb, line 5
def initialize doc, content, name
  super doc, content
  @name = name
end

Public Instance Methods

parse() click to toggle source
# File lib/minidown/elements/html_element.rb, line 10
def parse
  nodes << self
end
to_html() click to toggle source
# File lib/minidown/elements/html_element.rb, line 14
def to_html
  build_tag @name do |tag|
    # self.content is some Element
    self.content = content.text if ParagraphElement === self.content
    tag << self.content.to_html
  end
end