PHPackages                             knplabs/knp-menu-silex - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. knplabs/knp-menu-silex

AbandonedArchivedLibrary[Utility &amp; Helpers](/categories/utility)

knplabs/knp-menu-silex
======================

Integration of knplabs/knp-menu into Silex

v1.0.1(8y ago)21252[2 PRs](https://github.com/KnpLabs/KnpMenuServiceProvider/pulls)MITPHPPHP &gt;=5.3.0

Since Aug 22Pushed 3y ago11 watchersCompare

[ Source](https://github.com/KnpLabs/KnpMenuServiceProvider)[ Packagist](https://packagist.org/packages/knplabs/knp-menu-silex)[ Docs](https://knplabs.com)[ RSS](/packages/knplabs-knp-menu-silex/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (2)Dependencies (4)Versions (4)Used By (0)

DEPRECATED
==========

[](#deprecated)

Unfortunately we decided to not maintain this project anymore ([see why](https://knplabs.com/en/blog/news-for-our-foss-projects-maintenance)). If you want to mark another package as a replacement for this one please send an email to .

KnpMenuServiceProvider
======================

[](#knpmenuserviceprovider)

Silex service provider for the KnpMenu library.

[![Build Status](https://camo.githubusercontent.com/cc456d377341c616f6804bb61ab6c7c1cdbf5358407ccaf77b83bc928794eeca/68747470733a2f2f7472617669732d63692e6f72672f4b6e704c6162732f4b6e704d656e755365727669636550726f76696465722e737667)](http://travis-ci.org/KnpLabs/KnpMenuServiceProvider)[![Latest Stable Version](https://camo.githubusercontent.com/a13ca08064679025dbba270907ad2c1905b6047f38c4020c4d06f303c2127d25/68747470733a2f2f706f7365722e707567782e6f72672f6b6e706c6162732f6b6e702d6d656e752d73696c65782f762f737461626c652e737667)](https://packagist.org/packages/knplabs/knp-menu-silex)[![Latest Unstable Version](https://camo.githubusercontent.com/ea98afbf83fd713fb89a812d4cc69b11d551801ecf72b33eab9b1b290642cc6d/68747470733a2f2f706f7365722e707567782e6f72672f6b6e706c6162732f6b6e702d6d656e752d73696c65782f762f756e737461626c652e737667)](https://packagist.org/packages/knplabs/knp-menu-silex)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/9f03dfe6b7ab4b336145b3406f336d99f9efb4a776caea7b4ce755fc83874af9/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f4b6e704c6162732f4b6e704d656e755365727669636550726f76696465722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/KnpLabs/KnpMenuServiceProvider/?branch=master)

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

[](#installation)

Installation is done using Composer:

```
$ composer require knplabs/knp-menu-silex
```

Usage
-----

[](#usage)

Register the MenuServiceProvider in your application:

```
use Knp\Menu\Silex\MenuServiceProvider;

$app->register(new MenuServiceProvider());
```

#### Parameters

[](#parameters)

- **knp\_menu.menus** (optional): an array of `alias => id` pair for the [menu provider](02-Twig-Integration.markdown#menu-provider).
- **knp\_menu.renderers** (optional): an array of `alias => id` pair for the [renderer provider](02-Twig-Integration.markdown#renderer-provider).
- **knp\_menu.default\_renderer** (optional): the alias of the default renderer (default to `'list'`)
- **knp\_menu.template** (optional): The template used by default by the TwigRenderer.

#### Services

[](#services)

- **knp\_menu.factory**: The menu factory (it is a router-aware one if the UrlGeneratorServiceProvider is registered)
- **knp\_menu.renderer.list**: The ListRenderer
- **knp\_menu.renderer.twig**: The TwigRenderer (only when the Twig integration is available)
- **knp\_menu.menu\_manipulator**: The MenuManipulator
- **knp\_menu.matcher**: The KnpMenu Matcher
- **knp\_menu.voter.route**: The RouteVoter registered in the matcher. Unset it from the container to unregister it.

> **WARNING**The Twig integration is available only when the MenuServiceProvider is registered **after** the TwigServiceProvider in your application.

###  Health Score

29

—

LowBetter than 60% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 85% 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

3186d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/75c5d927b0434111db9720dd78af8c83385cf28bb9aeafd031ba8cb0c4ffc558?d=identicon)[Stof](/maintainers/Stof)

---

Top Contributors

[![stof](https://avatars.githubusercontent.com/u/439401?v=4)](https://github.com/stof "stof (17 commits)")[![docteurklein](https://avatars.githubusercontent.com/u/109846?v=4)](https://github.com/docteurklein "docteurklein (2 commits)")[![PedroTroller](https://avatars.githubusercontent.com/u/1766827?v=4)](https://github.com/PedroTroller "PedroTroller (1 commits)")

---

Tags

treemenusilex

### Embed Badge

![Health badge](/badges/knplabs-knp-menu-silex/health.svg)

```
[![Health](https://phpackages.com/badges/knplabs-knp-menu-silex/health.svg)](https://phpackages.com/packages/knplabs-knp-menu-silex)
```

###  Alternatives

[knplabs/knp-menu

An object oriented menu library

1.4k55.8M287](/packages/knplabs-knp-menu)[knplabs/knp-menu-bundle

This bundle provides an integration of the KnpMenu library

1.4k53.8M315](/packages/knplabs-knp-menu-bundle)[igorw/config-service-provider

A config ServiceProvider for Silex with support for php, json and yaml.

215636.5k13](/packages/igorw-config-service-provider)[asgardcms/menu-module

Menu module for AsgardCMS. Handles all the menus.

1030.4k2](/packages/asgardcms-menu-module)[icings/menu

A KnpMenu seasoned menu plugin for CakePHP.

1266.4k1](/packages/icings-menu)

PHPackages © 2026

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