twig loop associative array code example
Example 1: how to for loop twig
{% for i in 0..10 %}
* {{ i }}
{% endfor %}
Example 2: how to for loop twig
{% for letter in 'a'..'z' %}
* {{ letter }}
{% endfor %}
{% for i in 0..10 %}
* {{ i }}
{% endfor %}
{% for letter in 'a'..'z' %}
* {{ letter }}
{% endfor %}