menu_subtree

Get the subtree of an id in a menu (if any).

Returns the subtree of the filter value. Useful for showing a part of a menu when browsing sub-pages.

If the given id is not found inside the menu, it returns undefined.

If no argument is given, it takes menu from the resource with the name main_menu.

Edit on GitHub

menu_flat Menu menu_trail

Referred by

Filters

Filters transform template variables before they are rendered.