Sha256: d212b6d5f445afa0318f4c457ee1144c6eb6a5ee02803070671108fa1fb7bd0b

Contents?: true

Size: 358 Bytes

Versions: 1

Compression:

Stored size: 358 Bytes

Contents

# Gist Liquid Tag
#
# Example:
#    {% gist 1234567 %}

module Jekyll
  class GistTag < Liquid::Tag
    def initialize(tag_name, gist, tokens)
      super
      @gist = gist.strip
    end

    def render(context)
      "<script src=\"https://gist.github.com/#{@gist}.js\"> </script>"
    end
  end
end

Liquid::Template.register_tag('gist', Jekyll::GistTag)

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jekyll-1.0.0.beta1 lib/jekyll/tags/gist.rb