Sha256: 91e22f028ef1c0e92972a76bdf568b0c8dae49ea28d7a3616e036d46ba84bec0

Contents?: true

Size: 688 Bytes

Versions: 1

Compression:

Stored size: 688 Bytes

Contents

# frozen_string_literal: true

require "meta-tags"

module Archangel
  module Liquid
    module Tags
      ##
      # Meta tags custom tag for Liquid
      #
      # Example
      #   {% meta_tags %}
      #
      class MetaTagsTag < ApplicationTag
        ##
        # Render the meta tgas for the theme
        #
        # @param context [Object] the Liquid context
        # @return [String] the meta tags
        #
        # :reek:UtilityFunction
        def render(context)
          context.registers[:view].display_meta_tags
        end
      end
    end
  end
end

::Liquid::Template.register_tag("meta_tags",
                                Archangel::Liquid::Tags::MetaTagsTag)

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
archangel-0.3.0 lib/archangel/liquid/tags/meta_tags_tag.rb