Skip to content

Instantly share code, notes, and snippets.

Charaf Salmi charafsalmi

Block or report user

Report or block charafsalmi

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
charafsalmi /
Created Jul 23, 2018 — forked from mohcinebe/
Online Resources For Web Developers (No Downloading)
charafsalmi / list.html.twig
Created Mar 3, 2017 — forked from garak/list.html.twig
Twig recursive macro
View list.html.twig
{% macro recursiveCategory(category) %}
{% import _self as self %}
<h4><a href="{{ path(category.route, category.routeParams) }}">{{ category }}</a></h4>
{% if category.children|length %}
{% for child in category.children %}
{{ self.recursiveCategory(child) }}
{% endfor %}
You can’t perform that action at this time.