class JekyllI18nMultiPage::TranslateTag
Attributes
markup[RW]
Public Class Methods
new(tag_name, translate_path, tokens)
click to toggle source
Calls superclass method
# File lib/jekyll_i18n_multi_page/translate_tag.rb, line 5 def initialize(tag_name, translate_path, tokens) super @translate_path = translate_path.strip end
Public Instance Methods
render(context)
click to toggle source
# File lib/jekyll_i18n_multi_page/translate_tag.rb, line 10 def render(context) I18n.t(@translate_path, locale: context['page']['i18n_locale']) end