lib/himekami/markdown/processor.rb in himekami-markdown-0.1.5 vs lib/himekami/markdown/processor.rb in himekami-markdown-0.1.6

- old
+ new

@@ -1,8 +1,8 @@ module Himekami module Markdown - class Processor + class Processor < BaseProcessor class << self def default_context { asset_root: "/images", } @@ -13,21 +13,9 @@ HTML::Pipeline::MarkdownFilter, HTML::Pipeline::SyntaxHighlightFilter, Filters::Checkbox, ] end - end - - def initialize(context = {}) - @context = self.class.default_context.merge(context) - end - - def call(input, context = {}) - HTML::Pipeline.new(filters, @context).call(input, context) - end - - def filters - @filters ||= self.class.default_filters end end end end