Sha256: 830e37a796ca9c8e90c8313c829c51f2d1cb83fa8dfc3b86092adbd738212e26

Contents?: true

Size: 525 Bytes

Versions: 9

Compression:

Stored size: 525 Bytes

Contents

module PictureTag
  module Instructions
    # Jekyll site info
    class Site < Instruction
      def source
        PictureTag.context.registers[:site]
      end
    end

    # Current page in jekyll site
    class Page < Instruction
      def source
        PictureTag.context.registers[:page]
      end
    end

    # Digs into jekyll context, returns current environment
    class JekyllEnv < Instruction
      def source
        PictureTag.context.environments.first['jekyll']['environment']
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
jekyll_picture_tag-2.1.2 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.1.1 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.1.0 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.0.4 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.0.3 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.0.2 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.0.1 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.0.0 lib/jekyll_picture_tag/instructions/children/context.rb
jekyll_picture_tag-2.0.0pre1 lib/jekyll_picture_tag/instructions/children/context.rb