mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-13 02:46:29 +00:00
tweaked the iterable example in the docs
This commit is contained in:
@@ -11,6 +11,9 @@
|
||||
{# evaluates to true if the foo variable is iterable #}
|
||||
{% if users is iterable %}
|
||||
{% for user in users %}
|
||||
- {{ user }}
|
||||
Hello {{ user }}!
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
{# users is probably a string #}
|
||||
Hello {{ users }}!
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user