Module: Jekyll::TranslateFilter

Defined in:
lib/jekyll-i18n.rb

Overview

Necessary filter when you need multi-language site variables (e.g. menus)

Instance Method Summary collapse

Instance Method Details

#translate(input) ⇒ Object Also known as: t


31
32
33
34
# File 'lib/jekyll-i18n.rb', line 31

def translate(input)
	I18n.locale = @context.registers[:page]['lang'].intern
	I18n.t(input.strip)
end