Sha256: d5d3c2d87d4e7caca8d88d1d50023f2f79c70cc6dd8443abf1f97dcd71091a0d

Contents?: true

Size: 481 Bytes

Versions: 6

Compression:

Stored size: 481 Bytes

Contents

# encoding: utf-8

module Nanoc::Filters
  class Kramdown < Nanoc::Filter

    requires 'kramdown'

    # Runs the content through [Kramdown](http://kramdown.rubyforge.org/).
    # Parameters passed to this filter will be passed on to Kramdown.
    #
    # @param [String] content The content to filter
    #
    # @return [String] The filtered content
    def run(content, params = {})
      # Get result
      ::Kramdown::Document.new(content, params).to_html
    end

  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
nanoc-3.7.1 lib/nanoc/filters/kramdown.rb
nanoc-3.7.0 lib/nanoc/filters/kramdown.rb
nanoc-3.6.11 lib/nanoc/filters/kramdown.rb
nanoc-3.6.10 lib/nanoc/filters/kramdown.rb
nanoc-3.6.9 lib/nanoc/filters/kramdown.rb
nanoc-3.6.8 lib/nanoc/filters/kramdown.rb