summaryrefslogtreecommitdiff
path: root/examples/basic/translate.py
diff options
context:
space:
mode:
Diffstat (limited to 'examples/basic/translate.py')
-rw-r--r--examples/basic/translate.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/basic/translate.py b/examples/basic/translate.py
index fda8f7a..71547f4 100644
--- a/examples/basic/translate.py
+++ b/examples/basic/translate.py
@@ -12,7 +12,9 @@ print(
env.from_string(
"""\
{% trans %}Hello {{ user }}!{% endtrans %}
-{% trans count=users|count %}{{ count }} user{% pluralize %}{{ count }} users{% endtrans %}
+{% trans count=users|count -%}
+{{ count }} user{% pluralize %}{{ count }} users
+{% endtrans %}
"""
).render(user="someone", users=[1, 2, 3])
)