module Jekyll module Tags class RtitleTag < Liquid::Block def initialize(tag_name, block_options, liquid_options) super @title = block_options.strip end def render(context) site = context.registers[:site] converter = site.find_converter_instance(::Jekyll::Converters::Markdown) content = converter.convert(super) output = <<~EOS

#{@title}


#{content}
EOS output end end end end Liquid::Template.register_tag('rtitle', Jekyll::Tags::RtitleTag)