PHPackages                             dereuromark/cakephp-menu - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Templating &amp; Views](/categories/templating)
4. /
5. dereuromark/cakephp-menu

ActiveCakephp-plugin[Templating &amp; Views](/categories/templating)

dereuromark/cakephp-menu
========================

Composable menu builder and renderer for CakePHP

0.1.2(1mo ago)53.0k[1 issues](https://github.com/dereuromark/cakephp-menu/issues)[1 PRs](https://github.com/dereuromark/cakephp-menu/pulls)1MITPHPPHP &gt;=8.2CI passing

Since May 26Pushed 1w ago2 watchersCompare

[ Source](https://github.com/dereuromark/cakephp-menu)[ Packagist](https://packagist.org/packages/dereuromark/cakephp-menu)[ Docs](https://dereuromark.github.io/cakephp-menu/)[ RSS](/packages/dereuromark-cakephp-menu/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (3)Dependencies (4)Versions (5)Used By (1)

CakePHP Menu Plugin
===================

[](#cakephp-menu-plugin)

[![CI](https://github.com/dereuromark/cakephp-menu/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/dereuromark/cakephp-menu/actions/workflows/ci.yml?query=branch%3Amaster)[![Coverage Status](https://camo.githubusercontent.com/8c9b396445e234ea38943321048026b317b46f8ffb77f998adad8617eb453f39/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f6465726575726f6d61726b2f63616b657068702d6d656e752f6d61737465722e737667)](https://codecov.io/gh/dereuromark/cakephp-menu)[![PHPStan](https://camo.githubusercontent.com/f60d96f7c2579690ab6dfa8918f777fe93a02a92301c661eb38a85861a92b780/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048505374616e2d6c6576656c253230382d627269676874677265656e2e7376673f7374796c653d666c6174)](https://phpstan.org/)[![Latest Stable Version](https://camo.githubusercontent.com/90ef74567459a10f539648d45b9a3c069c1291723a5a8121fffab99b6c5ccad6/68747470733a2f2f706f7365722e707567782e6f72672f6465726575726f6d61726b2f63616b657068702d6d656e752f762f737461626c652e737667)](https://packagist.org/packages/dereuromark/cakephp-menu)[![Minimum PHP Version](https://camo.githubusercontent.com/ec21f169d70b69344c67d6f18fa1a24d20476d2f0cd680e8c4a1534c22f34e5f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d253345253344253230382e322d3838393242462e737667)](https://php.net/)[![License](https://camo.githubusercontent.com/c0860952092249d4e9ab1a32086e1207d473bf38c627c288ddaf022795be793f/68747470733a2f2f706f7365722e707567782e6f72672f6465726575726f6d61726b2f63616b657068702d6d656e752f6c6963656e73652e737667)](https://packagist.org/packages/dereuromark/cakephp-menu)[![Total Downloads](https://camo.githubusercontent.com/9209e87e25e282ef2a2391efbb5140fd332482f582b7d1c4d51408454c8e47aa/68747470733a2f2f706f7365722e707567782e6f72672f6465726575726f6d61726b2f63616b657068702d6d656e752f642f746f74616c2e737667)](https://packagist.org/packages/dereuromark/cakephp-menu)[![Coding Standards](https://camo.githubusercontent.com/7d06840986f78de39fb7ba7052db7208fb349427094ac1a4540449ca87776aff/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f63732d506870436f6c6c6563746976652d707572706c652e7376673f7374796c653d666c61742d737175617265)](https://github.com/php-collective/code-sniffer)

Composable menu builder and renderer for CakePHP applications.

This branch is for **CakePHP 5.3+**. See the [version map](https://github.com/dereuromark/cakephp-menu/wiki#cakephp-version-map) for details.

Features:

- nested menu trees with string and Cake-style array URLs
- active-state matching with alternate routes, named routes, and fuzzy matching
- helper-managed named menus and breadcrumb integration
- extensible resolvers and renderers for app-specific rules

Installation
------------

[](#installation)

```
composer require dereuromark/cakephp-menu
```

Load the plugin:

```
bin/cake plugin load Menu
```

Load the helper in your `AppView`:

```
use Cake\View\View;

class AppView extends View
{
    public function initialize(): void
    {
        parent::initialize();

        $this->loadHelper('Menu.Menu');
    }
}
```

Quick Start
-----------

[](#quick-start)

```
use Menu\Menu;

$menu = Menu::create(['class' => 'nav']);
$menu->addItem('Dashboard', ['controller' => 'Dashboard', 'action' => 'index']);

$account = $menu->addItem('Account', '#', [
    'attributes' => ['class' => 'nav-item'],
]);
$account->getSubMenu()->setAttributes(['class' => 'submenu']);
$account->add($menu->newItem('Profile', ['controller' => 'Users', 'action' => 'profile']));
$account->add($menu->newItem('Logout', ['controller' => 'Users', 'action' => 'logout']));

echo $this->Menu->render($menu);
```

Documentation
-------------

[](#documentation)

Full documentation lives at ****.

- [Getting Started](https://dereuromark.github.io/cakephp-menu/guide/)
- [Building Menus](https://dereuromark.github.io/cakephp-menu/guide/building)
- [Resolvers &amp; Active State](https://dereuromark.github.io/cakephp-menu/guide/resolvers)
- [Rendering](https://dereuromark.github.io/cakephp-menu/guide/rendering)
- [Recipes](https://dereuromark.github.io/cakephp-menu/guide/recipes)
- [Extending](https://dereuromark.github.io/cakephp-menu/guide/extending)

Demo
----

[](#demo)

###  Health Score

45

—

FairBetter than 91% of packages

Maintenance92

Actively maintained with recent releases

Popularity27

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity39

Early-stage or recently created project

 Bus Factor1

Top contributor holds 87.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

3

Last Release

36d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/39854?v=4)[Mark Scherer](/maintainers/dereuromark)[@dereuromark](https://github.com/dereuromark)

---

Top Contributors

[![dereuromark](https://avatars.githubusercontent.com/u/39854?v=4)](https://github.com/dereuromark "dereuromark (74 commits)")[![burzum](https://avatars.githubusercontent.com/u/162789?v=4)](https://github.com/burzum "burzum (10 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

---

Tags

buildermenunavigationtreepluginhelpercakephpmenuviewnavigation

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/dereuromark-cakephp-menu/health.svg)

```
[![Health](https://phpackages.com/badges/dereuromark-cakephp-menu/health.svg)](https://phpackages.com/packages/dereuromark-cakephp-menu)
```

###  Alternatives

[friendsofcake/cakephp-csvview

A CSV View class for CakePHP

1782.6M5](/packages/friendsofcake-cakephp-csvview)[dereuromark/cakephp-ajax

A CakePHP plugin that makes working with AJAX a piece of cake.

54262.9k1](/packages/dereuromark-cakephp-ajax)[dereuromark/cakephp-tinyauth

A CakePHP plugin to handle user authentication and authorization the easy way.

132240.2k13](/packages/dereuromark-cakephp-tinyauth)[dereuromark/cakephp-feed

A CakePHP plugin containing RssView and AtomView classes for generating RSS 2.0 and Atom 1.0 feeds.

1355.7k1](/packages/dereuromark-cakephp-feed)[dereuromark/cakephp-setup

A CakePHP plugin containing lots of useful management tools

36199.6k2](/packages/dereuromark-cakephp-setup)[dereuromark/cakephp-databaselog

A CakePHP plugin for storing and viewing application logs in the database

44172.5k2](/packages/dereuromark-cakephp-databaselog)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
