Update instructions to JINJA_ENVIRONMENT
JINJA_ENVIRONMENT replace JINJA_EXTENSIONS. It was changed in the example codes but not in the how to localize templates with Jinja2.
This commit is contained in:
parent
b5cde0aff5
commit
2f80133a69
@ -6,11 +6,13 @@ Localizing themes with Jinja2
|
||||
---------------------
|
||||
|
||||
To enable the |ext| extension in your templates, you must add it to
|
||||
``JINJA_EXTENSIONS`` in your Pelican configuration
|
||||
``JINJA_ENVIRONMENT`` in your Pelican configuration
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
JINJA_EXTENSIONS = ['jinja2.ext.i18n', ...]
|
||||
JINJA_ENVIRONMENT = {
|
||||
'extensions': ['jinja2.ext.i18n', ...]
|
||||
}
|
||||
|
||||
Then follow the `Jinja2 templating documentation for the I18N plugin
|
||||
<http://jinja.pocoo.org/docs/templates/#i18n>`_ to make your templates
|
||||
|
Loading…
x
Reference in New Issue
Block a user