PHPackages                             slope-it/breadcrumb-bundle - 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. slope-it/breadcrumb-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

slope-it/breadcrumb-bundle
==========================

A bundle for generating dynamic breadcrumbs in Symfony applications

2.1.2(12mo ago)1865.5k↓19.6%8[2 PRs](https://github.com/slope-it/breadcrumb-bundle/pulls)MITPHPPHP &gt;=8.1.0

Since Aug 11Pushed 12mo ago2 watchersCompare

[ Source](https://github.com/slope-it/breadcrumb-bundle)[ Packagist](https://packagist.org/packages/slope-it/breadcrumb-bundle)[ RSS](/packages/slope-it-breadcrumb-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (10)Versions (28)Used By (0)

SlopeItBreadcrumbBundle
=======================

[](#slopeitbreadcrumbbundle)

[![Latest Stable Version](https://camo.githubusercontent.com/4099e59b9f0d3f4ae1cb04c7fcd033305417c03d553dafadb456d4bd259380c5/68747470733a2f2f706f7365722e707567782e6f72672f736c6f70652d69742f62726561646372756d622d62756e646c652f762f737461626c65)](https://packagist.org/packages/slope-it/breadcrumb-bundle)[![Total Downloads](https://camo.githubusercontent.com/53b9647e2131fd35bdb3bc094887f318a314963c9bfe1770a656338af30c2b27/68747470733a2f2f706f7365722e707567782e6f72672f736c6f70652d69742f62726561646372756d622d62756e646c652f646f776e6c6f616473)](https://packagist.org/packages/slope-it/breadcrumb-bundle)[![License](https://camo.githubusercontent.com/79ff314f29b5e16224724b1503e5046305e19e23cc5ae98378025d00b6ae137c/68747470733a2f2f706f7365722e707567782e6f72672f736c6f70652d69742f62726561646372756d622d62756e646c652f6c6963656e7365)](https://packagist.org/packages/slope-it/breadcrumb-bundle)

This bundle provides a way to create "dynamic" breadcrumbs in your Symfony applications.

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

[](#installation)

Composer is the only supported installation method. Run the following to install the latest version from Packagist:

```
composer require slope-it/breadcrumb-bundle
```

Or, if you prefer, you can require any version in your `composer.json`:

```
{
    "require": {
        "slope-it/breadcrumb-bundle": "*"
    }
}
```

Usage
-----

[](#usage)

### 1. Load bundle

[](#1-load-bundle)

Once installed, load the bundle in your Kernel class:

```
// ...
class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = [
            // ...
            new SlopeIt\BreadcrumbBundle\SlopeItBreadcrumbBundle(),
        ];
        // ...
    }
    // ...
}
```

### 2. Define breadcrumbs

[](#2-define-breadcrumbs)

There are two ways to create a breadcrumb: via code (1) or via attributes (2).

*Via code*: you can inject the breadcrumb builder in your controller and add breadcrumb items:

```
