Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Simplify Menu

Security covered Maintenance fixes only 8,305 sites

The simplify_menu module allows you to access and customize Drupal menu structures directly within your Twig templates. This provides full control over the menu's render array, enabling easier markup customization for accessibility and standards compliance.

The simplify_menu module uses a TwigExtension to gain access to Drupal's main menu's (or any other menu for that matter), render array so it can be accessed from a twig template. Among the many advantages of having full control of the menu's render array in a twig template is the ability to customize the markup for your menus to ensure they are accessible and comply with standards.

How to use

{# Get menu items #}
{% set items = simplify_menu('main') %}

{# Iterate menu tree #}
<nav class="navigation__items">
  {% for menu_item in items.menu_tree %}
    <li class="navigation__item">
      <a href="{{ menu_item.url }}">{{ menu_item.text }}</a>
    </li>
  {% endfor %}
</nav>

Blog post

Read a detailed blog post by Tim Dickens of Mediacurrent.
https://www.mediacurrent.com/blog/simplify-menu-and-twig-macros

Drupal 9–11

Ask your assistant about Simplify Menu

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
8
Tracked since
Jun 2023
Latest release
1 year ago
Releases (12 mo)
0 ▼ from 2
Maintenance
Dormant

Release Timeline

Releases

Version Type Core PHP Release date
3.3.0 Stable 9–11 Dec 13, 2024
3.x-dev Dev 9–11 Dec 13, 2024
3.2.0 Stable 9–10 Aug 1, 2024
3.1.x-dev Dev 9–11 Aug 1, 2023
3.1.1 Stable 9–10 Jul 28, 2023
3.1.0 Stable 9–10 Jul 26, 2023
3.0.0 Stable 8–9 Jul 26, 2023
3.0.0-beta1 Pre-release 9–10 Jun 7, 2023