Expose the current language to templates
UltCombo opened this issue · comments
Fabricio Matte commented
All templates (index, post, page and category) should have a global variable indicating in which language it is being rendered.
This, coupled with config's custom properties, will allow for rudimentary i18n using keyed dictionaries. There are many other interesting language-specific use cases that this will cover as well.
As for the naming, I believe lang
is a suitable global variable name.
Jaydson Gomes commented
Hey! Thanks for this @UltCombo !