{% for link in links %} {% if link is iterable %} {{ link.text | raw }} {% else %} {{ link | raw }} {% endif %} {% endfor %}