Create clean_html.rb

pull/442/head
Julian Böhnke 9 years ago
parent 6428cee512
commit a1dba5d989

@ -0,0 +1,19 @@
module Docs
class Phalcon
class CleanHtmlFilter < Filter
def call
@doc = at_css('.body')
# Remove unnecessary things
css('').remove
# Add id for constants and methods
css('#constants strong', '#methods strong').each do |node|
node.parent['id'] = node.content.strip
end
doc
end
end
end
end
Loading…
Cancel
Save