nyoncode / wire-module-users
User administration for wire: a ready-made module with its resource, pages and optional role management.
Requires
- php: ^8.2
- illuminate/database: ^12.0|^13.0
- illuminate/support: ^12.0|^13.0
- livewire/livewire: ^4.0
- nyoncode/laravel-package-toolkit: ^2.5.0
- nyoncode/wire-core: 2.0.0
- nyoncode/wire-forms: 2.0.0
- nyoncode/wire-panels: 2.0.0
- nyoncode/wire-table: 2.0.0
Requires (Dev)
- laravel/pint: ^1.29
- nyoncode/laravel-permission-extended: ^1.0
- orchestra/testbench: ^10.0|^11.0
- pestphp/pest: ^4.0|^5.0
Suggests
- nyoncode/laravel-permission-extended: Adds role and permission management to the module, with wildcard permissions and a super-admin gate.
Provides
None
Conflicts
None
Replaces
None
README
Wire Module Users
A ready-made users area for Wire, installed as a package — and the reference implementation of how a module ships as one.
composer require nyoncode/wire-module-users php artisan wire-module-users:install
The application lists nothing and edits no config: the module registers itself through the plugin manager during its provider's register phase, and the core provider spreads its resources and its menu group into the registries that own them.
What it manages
Your user model, not one of its own — config('wire-module-users.model') points
at App\Models\User, and the three columns it touches are configuration too,
because users is the one table every application has changed.
| Screen | Notes |
|---|---|
| Users list, create, edit, view | The password field is empty on edit and means keep the current one; a typed one is hashed |
| Roles list, create, edit | Only where roles exist. Permissions are edited as names, so a wildcard is just a name |
Roles appear when nyoncode/laravel-permission-extended is installed and the
user model carries its HasRoles trait. Both are checked: the package can be
installed while the model never took the trait, and every role save would then
fail at its last step.
That package and not the spatie/laravel-permission it is built on — these
screens assume its wildcard matching, its super-admin gate and its
permission-change events, so a model on bare Spatie is deliberately not detected.
'roles' => true overrules the look.
What it does not do
Authorization. Every check in this stack is Gate::allows(), which both
permission packages register themselves into, so wildcards (invoices.*) and a
super-admin bypass work without this module knowing they exist. Who may manage
users is your policy.
Authentication. Login, password reset and two-factor are Laravel's, through
Fortify or Breeze. wire-admin ships the card they render inside.
Documentation
Full docs: docs/modules/users.md
(česky).
License
MIT.