PHPackages                             sumantablog/dragndroplaravelmenu - 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. sumantablog/dragndroplaravelmenu

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

sumantablog/dragndroplaravelmenu
================================

Drag And Drop Menu Builder in Laravel

1.0.0(6y ago)015MITJavaScriptPHP &gt;=7.1

Since Jan 2Pushed 6y ago1 watchersCompare

[ Source](https://github.com/sumantablog/dragndroplaravelmenu)[ Packagist](https://packagist.org/packages/sumantablog/dragndroplaravelmenu)[ RSS](/packages/sumantablog-dragndroplaravelmenu/feed)WikiDiscussions master Synced yesterday

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

Laravel Drag and Drop menu Builder
==================================

[](#laravel-drag-and-drop-menu-builder)

[![Latest Stable Version](https://camo.githubusercontent.com/dd66e99915315fae0dc7b78605c35a229b0b95768ec61483d3cb9976bc179dcd/68747470733a2f2f706f7365722e707567782e6f72672f73756d616e7461626c6f672f647261676e64726f706c61726176656c6d656e752f762f737461626c65)](https://packagist.org/packages/sumantablog/dragndroplaravelmenu) [![Latest Unstable Version](https://camo.githubusercontent.com/bf41719d1791a0fd9b6ead36061da01ea672414144b05035bdb5bc38af6b76b1/68747470733a2f2f706f7365722e707567782e6f72672f73756d616e7461626c6f672f647261676e64726f706c61726176656c6d656e752f762f756e737461626c65)](https://packagist.org/packages/sumantablog/dragndroplaravelmenu)[![Total Downloads](https://camo.githubusercontent.com/4e03d22c54ca1b838d08d73491b7ba2ee85312a10515d030d8747a55d522cbb7/68747470733a2f2f706f7365722e707567782e6f72672f73756d616e7461626c6f672f647261676e64726f706c61726176656c6d656e752f646f776e6c6f616473)](https://packagist.org/packages/sumantablog/dragndroplaravelmenu)[![License](https://camo.githubusercontent.com/487bf95b4cb598c6d7ea84655660f4a447a4a4ddd5202a51507b4ede247cb85e/68747470733a2f2f706f7365722e707567782e6f72672f73756d616e7461626c6f672f647261676e64726f706c61726176656c6d656e752f6c6963656e7365)](https://packagist.org/packages/sumantablog/dragndroplaravelmenu)[![composer.lock](https://camo.githubusercontent.com/18300165016359f668038612be6a1ac5932942092d730e501e5d18c12a637e69/68747470733a2f2f706f7365722e707567782e6f72672f73756d616e7461626c6f672f647261676e64726f706c61726176656c6d656e752f636f6d706f7365726c6f636b)](https://packagist.org/packages/sumantablog/dragndroplaravelmenu)forked from [![Laravel drag and drop menu](https://raw.githubusercontent.com/sumantablog/dragndroplaravelmenu/master/screenshot.png)](https://raw.githubusercontent.com/sumantablog/dragndroplaravelmenu/master/screenshot.png)

### Installation

[](#installation)

1. Run

```
composer require sumantablog/dragndroplaravelmenu
```

***Step 2 &amp; 3 are optional if you are using laravel 5.5***

2. Add the following class, to "providers" array in the file config/app.php (optional on laravel 5.5)

```
Sumantablog\Menu\MenuServiceProvider::class,
```

3. add facade in the file config/app.php (optional on laravel 5.5)

```
'Menu' => Sumantablog\Menu\Facades\Menu::class,
```

4. Run publish

```
php artisan vendor:publish --provider="Sumantablog\Menu\MenuServiceProvider"
```

5. Configure (optional) in ***config/menu.php*** :

- ***CUSTOM MIDDLEWARE:*** You can add you own middleware
- ***TABLE PREFIX:*** By default this package will create 2 new tables named "menus" and "menu\_items" but you can still add your own table prefix avoiding conflict with existing table
- ***TABLE NAMES*** If you want use specific name of tables you have to modify that and the migrations
- ***Custom routes*** If you want to edit the route path you can edit the field
- ***Role Access*** If you want to enable roles (permissions) on menu items

6. Run migrate

```
php artisan migrate
```

DONE

### Menu Builder Usage Example - displays the builder

[](#menu-builder-usage-example---displays-the-builder)

On your view blade file

```
@extends('app')

@section('contents')
    {!! Menu::render() !!}
@endsection

//YOU MUST HAVE JQUERY LOADED BEFORE menu scripts
@push('scripts')
    {!! Menu::scripts() !!}
@endpush
```

### Get Menu Items By Menu ID

[](#get-menu-items-by-menu-id)

```
use Sumantablog\Menu\Facades\Menu;
...
/*
Parameter: Menu ID
Return: Array
*/
$menuList = Menu::get(1);
```

### Get Menu Items By Menu Name

[](#get-menu-items-by-menu-name)

In this example, you must have a menu named *Admin*

```
use Sumantablog\Menu\Facades\Menu;
...
/*
Parameter: Menu ID
Return: Array
*/
$menuList = Menu::getByName('Admin');
```

### Using The Model

[](#using-the-model)

Call the model class

```
use Sumantablog\Menu\Models\Menus;
use Sumantablog\Menu\Models\MenuItems;
```

### Menu Usage Example (a)

[](#menu-usage-example-a)

A basic two-level menu can be displayed in your blade template

```
// Used to get the menu items into the blade template
$public_menu = Menu::getByName('Public');
```

### Menu Usage Example (b)

[](#menu-usage-example-b)

Now inside your blade template file place the menu using this simple example

```

        @if($public_menu)

            @foreach($public_menu as $menu)

                {{ $menu['label'] }}
                @if( $menu['child'] )

                    @foreach( $menu['child'] as $child )
                        {{ $child['label'] }}
                    @endforeach

                @endif

            @endforeach
        @endif

```

### Customization

[](#customization)

you can edit the menu interface in ***resources/views/vendor/wmenu/menu-html.blade.php***

### Credits

[](#credits)

- [wmenu](https://github.com/lordmacu/wmenu) laravel package menu like wordpress

### Compatibility

[](#compatibility)

- Tested with laravel 5.2, 5.3, 5.4, 5.5, 5.6, 5.7, 5.8

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity52

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

Unknown

Total

1

Last Release

2375d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/a2f1e6cd57ef0ac0887df933ce67766d6eb6a616ee58b6508017b2272630bdf1?d=identicon)[sumantablog](/maintainers/sumantablog)

---

Top Contributors

[![infysumanta](https://avatars.githubusercontent.com/u/40049179?v=4)](https://github.com/infysumanta "infysumanta (3 commits)")

---

Tags

menu-builderlaravel-menuDrag Drop Menu

### Embed Badge

![Health badge](/badges/sumantablog-dragndroplaravelmenu/health.svg)

```
[![Health](https://phpackages.com/badges/sumantablog-dragndroplaravelmenu/health.svg)](https://phpackages.com/packages/sumantablog-dragndroplaravelmenu)
```

###  Alternatives

[spatie/laravel-menu

Html menu generator for Laravel

9822.9M11](/packages/spatie-laravel-menu)[biostate/filament-menu-builder

An Elegant Menu Builder for FilamentPHP

6528.1k2](/packages/biostate-filament-menu-builder)[awes-io/navigator

🧿 Build navigation or menu for Laravel and Awes.io. Unlimit complexity and depth of the menu.

4922.8k](/packages/awes-io-navigator)[laravel-enso/menus

Menu management for Laravel Enso

1644.0k25](/packages/laravel-enso-menus)[pceuropa/yii2-menu

Menu bootstrap builder. Sort by drag and drop

2812.0k](/packages/pceuropa-yii2-menu)[salahhusa9/laravel-menu

Html menu generator for Laravel

165.0k](/packages/salahhusa9-laravel-menu)

PHPackages © 2026

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