PHPackages                             chamber-orchestra/breadcrumbs - 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. chamber-orchestra/breadcrumbs

ActiveLibrary[Templating &amp; Views](/categories/templating)

chamber-orchestra/breadcrumbs
=============================

Lightweight, iterable breadcrumb collection for Symfony 8 applications

v8.0.3(3mo ago)1443↑16.7%1MITPHPPHP ^8.5CI passing

Since Feb 13Pushed 3mo agoCompare

[ Source](https://github.com/chamber-orchestra/breadcrumbs)[ Packagist](https://packagist.org/packages/chamber-orchestra/breadcrumbs)[ Docs](https://github.com/chamber-orchestra/breadcrumbs)[ RSS](/packages/chamber-orchestra-breadcrumbs/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (4)Versions (6)Used By (1)

[![PHP Composer](https://github.com/chamber-orchestra/breadcrumbs/actions/workflows/php.yml/badge.svg)](https://github.com/chamber-orchestra/breadcrumbs/actions/workflows/php.yml)[![PHP CS Fixer](https://camo.githubusercontent.com/38a469223430dcb2e92f6ade8149f377db8bda7d1b2c6fd04015fe6659faded0/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f504850253230435325323046697865722d656e61626c65642d627269676874677265656e2e737667)](https://github.com/PHP-CS-Fixer/PHP-CS-Fixer)[![Code Style: PER-CS](https://camo.githubusercontent.com/6ec1ce8cd297f8e9173b85f5c9b1831612578ea0e7fc8a55f3d33e1bdc049b57/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f64652532307374796c652d5045522d2d43532d626c75652e737667)](https://www.php-fig.org/per/coding-style/)[![Code Style: Symfony](https://camo.githubusercontent.com/4bdfc5c7cdcfe89ff8a5d1f818ff1c6b6e026546c788f6f88cf2dc28710985a5/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f64652532307374796c652d53796d666f6e792d626c61636b2e737667)](https://symfony.com/doc/current/contributing/code/standards.html)[![PHPStan Level max](https://camo.githubusercontent.com/b6d441ad4fe8332cb16c72aa27f22cc685181dfd74ae34964afc92c6c1146b3c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048505374616e2d6c6576656c2532306d61782d627269676874677265656e2e737667)](https://phpstan.org/)[![PHP 8.5](https://camo.githubusercontent.com/40afc499167234cbc9f48deebb4fac0b833dde32beb716e6737a26b359a4c0f9/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e352d3737374242342e737667)](https://www.php.net/)[![Symfony 8.0](https://camo.githubusercontent.com/daaa476b3cc456701380f7d0fbdc3bbe9983e89d3267f99870daa88aa719e181/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f53796d666f6e792d382e302d3030303030302e737667)](https://symfony.com/)[![Latest Stable Version](https://camo.githubusercontent.com/aa15afb9c1a96ec329f6737e8aa743519ae226baea8be20382879157fcda92d1/68747470733a2f2f706f7365722e707567782e6f72672f6368616d6265722d6f72636865737472612f62726561646372756d62732f76)](https://packagist.org/packages/chamber-orchestra/breadcrumbs)[![License](https://camo.githubusercontent.com/0a103d1ff5289f7a9fe9956f3cbab0fd45bae8b1ab0737d8ede1835ef8feadb5/68747470733a2f2f706f7365722e707567782e6f72672f6368616d6265722d6f72636865737472612f62726561646372756d62732f6c6963656e7365)](https://packagist.org/packages/chamber-orchestra/breadcrumbs)

Breadcrumbs
===========

[](#breadcrumbs)

A lightweight, iterable breadcrumb collection for Symfony applications. Implements `ArrayAccess`, `Iterator`, and `Countable` for seamless integration with Twig templates and controllers.

Part of the [Chamber Orchestra](https://github.com/chamber-orchestra) ecosystem.

Requirements
------------

[](#requirements)

- PHP ^8.5
- Symfony HttpFoundation ^8.0

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

[](#installation)

```
composer require chamber-orchestra/breadcrumbs
```

Usage
-----

[](#usage)

### Adding breadcrumbs manually

[](#adding-breadcrumbs-manually)

```
use ChamberOrchestra\Breadcrumbs\Breadcrumbs;

$breadcrumbs = new Breadcrumbs();
$breadcrumbs
    ->addCrumb('Home', 'app_home')
    ->addCrumb('Products', 'app_products', ['category' => 'books'])
    ->addCrumb('Current Page');
```

### Adding from a Symfony Request

[](#adding-from-a-symfony-request)

```
$breadcrumbs->addRequestCrumb('Current Page', $request);
```

Extracts `_route` and `_route_params` from the request attributes automatically.

### Prepending a crumb

[](#prepending-a-crumb)

```
$breadcrumbs->addCrumb('Home', 'app_home', [], prepend: true);
```

### Using a closure

[](#using-a-closure)

```
$breadcrumbs->addCrumbsClosure(function (Breadcrumbs $crumbs) {
    $crumbs->addCrumb('Home', 'app_home');
    $crumbs->addCrumb('About', 'app_about');
});
```

### Iterating in Twig

[](#iterating-in-twig)

```

        {% for crumb in breadcrumbs %}

                {% if crumb.route %}
                    {{ crumb.name }}
                {% else %}
                    {{ crumb.name }}
                {% endif %}

        {% endfor %}

```

### Array access

[](#array-access)

```
$first = $breadcrumbs[0];
$total = count($breadcrumbs);
```

License
-------

[](#license)

MIT

###  Health Score

44

—

FairBetter than 92% of packages

Maintenance82

Actively maintained with recent releases

Popularity20

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

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

4

Last Release

91d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/44037eb1c8dc2c4fa9871ac213653f33e22a9348dcec7132df07cc71933f2a2e?d=identicon)[wtorsi](/maintainers/wtorsi)

---

Top Contributors

[![wtorsi](https://avatars.githubusercontent.com/u/2115840?v=4)](https://github.com/wtorsi "wtorsi (2 commits)")

---

Tags

breadcrumbsnavigationphpphp-librarysymfonysymfony-bundlesymfony8twigphpsymfonytwignavigationbreadcrumbsiterablearray-access

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/chamber-orchestra-breadcrumbs/health.svg)

```
[![Health](https://phpackages.com/badges/chamber-orchestra-breadcrumbs/health.svg)](https://phpackages.com/packages/chamber-orchestra-breadcrumbs)
```

###  Alternatives

[nucleos/antispam-bundle

This bundle provides some basic features to reduce spam in symfony forms.

52105.1k](/packages/nucleos-antispam-bundle)[oskarstark/symfony-http-responder

This library provides a Symfony responder class, which can be used to render a template, return json or a file and redirect to route/url.

13811.0k2](/packages/oskarstark-symfony-http-responder)[goetas/twital-bundle

Twital templating engine Symfony Bundle

206.8k](/packages/goetas-twital-bundle)

PHPackages © 2026

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