Module: Reacco::Filters::PreLang

Included in:
Readme
Defined in:
lib/reacco/filters/prelang.rb

Instance Method Summary collapse

Instance Method Details

#pre_lang(html) ⇒ Object

Adds prettify classes.



5
6
7
8
# File 'lib/reacco/filters/prelang.rb', line 5

def pre_lang(html)
  html.css('pre').each { |pre| pre['class'] = "#{pre['class']} lang-#{pre['class']} prettyprint" }
  html
end