Answers for "twig for i"

3

twig foreach

{% for key, value in array %}
  {{ key }}: {{ value }}
{% endfor %}
Posted by: Guest on September-25-2020
2

twig for

<ul>
    {% for key, user in users %}
        <li>{{ key }}: {{ user.username|e }}</li>
    {% endfor %}
</ul>
Posted by: Guest on July-16-2020
1

how to for loop twig

{% for i in 0..10 %}
    * {{ i }}
{% endfor %}
Posted by: Guest on April-29-2020
0

twig for

{% for i in 0..10 %}
    * {{ i }}
{% endfor %}
Posted by: Guest on February-19-2021

Browse Popular Code Answers by Language