Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Permission Extended Laravel Package

nyoncode/laravel-permission-extended

View on GitHub
Deep Wiki
Context7

Installation

composer require nyoncode/laravel-permission-extended
php artisan permission-extended:install

The install command will:

  1. Publish config/permission-extended.php
  2. Publish Spatie's permission migration tables
  3. Ask to run migrations
  4. Optionally register the service provider

Manual Setup

Change the HasRoles import — from Spatie to this package:

// Before:  use Spatie\Permission\Traits\HasRoles;
// After:
use NyonCode\PermissionExtended\Traits\HasRoles;

class User extends Authenticatable
{
    use HasRoles;
}

Do not use both Spatie's and this package's HasRoles on the same model.

Verify

$user = User::first();
$user->givePermissionTo('admin.create');
$user->hasPermissionTo('admin.*'); // true
$user->can('admin.*');             // true (via Gate)
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
jayeshmepani/jpl-moshier-ephemeris-php
elnasnato/laraliveui
labrodev/rest-sdk
sampaui/sampaui
babelqueue/php-sdk
facebook/capi-param-builder-php
babelqueue/symfony
hamzi/corewatch
minionfactory/raw-hydrator
hexters/coinpayment
rjcodes/rjcms
act-training/laravel-permissions-manager
alimarchal/laravel-chart-of-accounts
babenkoivan/elastic-scout-driver
mkwebdesign/filament-watchdog-v5
renatomarinho/laravel-page-speed
zedmagdy/filament-business-hours
renatovdemoura/blade-elements-ui
devgeek/beacon-admin
benjamin-rqt/data-watcher-bundle