Hi,

I am using Jinja2 instead of the Django template system in a test
project. Everything is working fine, but I am running into a small
problem regarding i18n:

The command "django-admin makemessages" doesn't find the translation
strings, because the Jinja2 format differs from the Django format.

Django syntax:
{% trans "Hello" %}
{% blocktrans %}Hello{% endblocktrans %}

Jinj2 syntax:
{{ _('Hello') }}
{% trans %}Hello{% endtrans %}

The underscore syntax work fine, but the trans/endtrans doesn't: the
regular expressions used by makemessages don't account for a different
syntax. As far as I can see there is no possible way to configure the
system so it can work with different i18n syntaxes. It seems like a
good idea to open this up, so different template systems can be used
more easily.

Would it be a good idea suggest this in a ticket?

Cheers,
Kevin Renskers

--

You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.


Reply via email to