Class: Jekyll::MarkdownBlock

Inherits:
Liquid::Block
  • Object
show all
Defined in:
jekyll/_plugins/jekyll-markdown-block.rb

Instance Method Summary collapse

Constructor Details

#initialize(tag_name, markup, tokens) ⇒ MarkdownBlock

Returns a new instance of MarkdownBlock.



5
6
7
# File 'jekyll/_plugins/jekyll-markdown-block.rb', line 5

def initialize(tag_name, markup, tokens)
    super
end

Instance Method Details

#render(context) ⇒ Object

Uses the default Jekyll markdown parser to parse the contents of this block



12
13
14
15
16
17
18
19
20
21
# File 'jekyll/_plugins/jekyll-markdown-block.rb', line 12

def render(context)
    site = context.registers[:site]
    converter =
    if site.respond_to?(:find_converter_instance)
        site.find_converter_instance(Jekyll::Converters::Markdown)
    else
        site.getConverterImpl(Jekyll::Converters::Markdown)
    end
    converter.convert(render_block(context))
end

#render_blockObject



3
# File 'jekyll/_plugins/jekyll-markdown-block.rb', line 3

alias_method :render_block, :render