PHPackages                             garrettweinberg/sage-bootstrap5-navwalker - 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. garrettweinberg/sage-bootstrap5-navwalker

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

garrettweinberg/sage-bootstrap5-navwalker
=========================================

Bootstrap 5 Navbar component navwalker for Sage 10 based themes

1.4(3y ago)932.9k↓11.5%3[1 issues](https://github.com/GarrettWeinberg/sage-bootstrap5-navwalker/issues)MITPHPPHP &gt;=5.3.2

Since Apr 19Pushed 3y ago1 watchersCompare

[ Source](https://github.com/GarrettWeinberg/sage-bootstrap5-navwalker)[ Packagist](https://packagist.org/packages/garrettweinberg/sage-bootstrap5-navwalker)[ Docs](https://github.com/garrettweinberg/sage-bootstrap5-navwalker)[ RSS](/packages/garrettweinberg-sage-bootstrap5-navwalker/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (5)DependenciesVersions (6)Used By (0)

Sage 10 friendly Bootstrap 5 Navwalker
======================================

[](#sage-10-friendly-bootstrap-5-navwalker)

**Forked from [MWDelaney/sage-bootstrap4-navwalker](https://github.com/MWDelaney/sage-bootstrap4-navwalker)**

Sets up a Bootstrap 5 Navwalker for Sage 10 based themes.

To install, run the following in your Sage 10 based theme directory:

```
composer require "garrettweinberg/sage-bootstrap5-navwalker"
```

Include the navwalker in your `wp_nav_menu` function:

As a [Controller](https://github.com/soberwp/controller) method (Recommended)
-----------------------------------------------------------------------------

[](#as-a-controller-method-recommended)

In your Controller, probably `app.php`

```
public function with()
    {
        return [
            'primaryNavigation' => $this->primaryNavigation(),
        ];
    }

/**
 * Primary Nav Menu arguments
 * @return array
 */
public function primaryNavigation()
    {
        $args = array(
            'theme_location' => 'primary_navigation',
            'container'  => '',
            'container_class' => '',
            'menu_class' => 'navbar-nav',
            'depth' => 4,
            'fallback_cb' => 'wp_bootstrap_navwalker::fallback',
            'walker' => new \App\wp_bootstrap5_navwalker()
        );
        return $args;
    }
```

In your Blade file, probably `header.blade.php`

```
@if (has_nav_menu('primary_navigation'))
  {!! wp_nav_menu($primaryNavigation) !!}
@endif
```

Without Controller
------------------

[](#without-controller)

If you're not setting up your template data with Controller, you'll need to fully reference the `\App\wp_bootstrap5_navwalker()`. In your Blade file, probably `header.blade.php`

```
@if (has_nav_menu('primary_navigation'))
  {!! wp_nav_menu(['theme_location' => 'primary_navigation', 'menu_class' => 'navbar-nav', 'walker' => new \App\wp_bootstrap5_navwalker()]) !!}
@endif
```

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance18

Infrequent updates — may be unmaintained

Popularity35

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 90% 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 ~138 days

Total

5

Last Release

1300d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/5b1c31c00445e4a1b09b20b7cd4eec7b282e2793e7dbe5f93ea7df0c542c1abc?d=identicon)[garrettweinberg](/maintainers/garrettweinberg)

---

Top Contributors

[![GarrettWeinberg](https://avatars.githubusercontent.com/u/32328986?v=4)](https://github.com/GarrettWeinberg "GarrettWeinberg (9 commits)")[![MWDelaney](https://avatars.githubusercontent.com/u/2457670?v=4)](https://github.com/MWDelaney "MWDelaney (1 commits)")

---

Tags

wordpressnavbarnavwalkerbootstrap-5

### Embed Badge

![Health badge](/badges/garrettweinberg-sage-bootstrap5-navwalker/health.svg)

```
[![Health](https://phpackages.com/badges/garrettweinberg-sage-bootstrap5-navwalker/health.svg)](https://phpackages.com/packages/garrettweinberg-sage-bootstrap5-navwalker)
```

###  Alternatives

[log1x/navi

A developer-friendly alternative to the WordPress NavWalker.

367633.2k7](/packages/log1x-navi)[php-stubs/wordpress-stubs

WordPress function and class declaration stubs for static analysis.

19513.0M263](/packages/php-stubs-wordpress-stubs)[mwdelaney/sage-bootstrap4-navwalker

Bootstrap 4 Navbar component navwalker for Sage 9 based themes

7397.5k](/packages/mwdelaney-sage-bootstrap4-navwalker)[wpsitecare/carelib

A collection of helpful functions to make creating an awesome theme more enjoyable.

164.6k](/packages/wpsitecare-carelib)[bostondv/bootstrap-ninja-forms

Adds Bootstrap classes to Ninja Forms

222.2k](/packages/bostondv-bootstrap-ninja-forms)

PHPackages © 2026

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