Class: MarkdownToHtml::HTMLWithPygments
- Inherits:
-
Redcarpet::Render::HTML
- Object
- Redcarpet::Render::HTML
- MarkdownToHtml::HTMLWithPygments
- Includes:
- Redcarpet::Render::SmartyPants
- Defined in:
- lib/markdown_to_html.rb
Instance Method Summary collapse
Instance Method Details
#block_code(code, language) ⇒ Object
10 11 12 13 14 |
# File 'lib/markdown_to_html.rb', line 10 def block_code(code, language) = { :encoding => 'utf-8'} [:lexer] = language unless language.nil? Pygments.highlight(code, ) end |