Module: CommonMarker::Rouge
- Defined in:
- lib/commonmarker/rouge.rb,
lib/commonmarker/rouge/version.rb
Constant Summary collapse
- VERSION =
'1.2.0'
Class Method Summary collapse
- .render_doc(text, cmark_options = :DEFAULT, **highmark_options) ⇒ Object
- .render_html(text, cmark_options = :DEFAULT) ⇒ Object
Class Method Details
.render_doc(text, cmark_options = :DEFAULT, **highmark_options) ⇒ Object
11 12 13 14 15 16 17 |
# File 'lib/commonmarker/rouge.rb', line 11 def render_doc(text, = :DEFAULT, **) cmark = [:cmark_class] || ::CommonMarker ast = cmark.render_doc(text, ) process_ast(ast, ) ast end |
.render_html(text, cmark_options = :DEFAULT) ⇒ Object
19 20 21 |
# File 'lib/commonmarker/rouge.rb', line 19 def render_html(text, = :DEFAULT) render_doc(text, ).to_html end |