Class: Remark

Inherits:
Object
  • Object
show all
Defined in:
lib/remark.rb

Constant Summary collapse

IGNORE =
%w(script head style)

Instance Method Summary collapse

Constructor Details

#initialize(source) ⇒ Remark

Returns a new instance of Remark.



4
5
6
# File 'lib/remark.rb', line 4

def initialize(source)
  @doc = Hpricot(source)
end

Instance Method Details

#to_markdownObject



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

def to_markdown
  remark_children(@doc).join("\n\n")
end