robinwieske / laravel-action-command
This package provides a simple `make:action` command to generate invokable action classes
Fund package maintenance!
Robin Wieske
Requires
- php: ^8.2||^8.3||^8.4
- illuminate/contracts: ^10.0||^11.0
- spatie/laravel-package-tools: ^1.16
Requires (Dev)
- larastan/larastan: ^2.9||^3.0
- laravel/pint: ^1.14
- nunomaduro/collision: ^8.1.1||^7.10.0
- orchestra/testbench: ^9.0.0||^8.22.0
- pestphp/pest: ^3.0
- pestphp/pest-plugin-arch: ^3.0
- pestphp/pest-plugin-laravel: ^3.0
- phpstan/extension-installer: ^1.3||^2.0
- phpstan/phpstan-deprecation-rules: ^1.1||^2.0
- phpstan/phpstan-phpunit: ^1.3||^2.0
- spatie/laravel-ray: ^1.35
README
This package allows you to easily create Action
classes in your laravel project. You can either just use the
php artisan make:model
command and pass the --actions
flag to create Create{Model}Action
, Update{Model}Action
and Delete{Model}Action
actions or you can directly use php artisan make:action
.
Installation
You can install the package via composer:
composer require robinwieske/laravel-action-command
Usage
Create an action class directly:
php artisan action:make User/CreateUserAction
Or pass the --actions
flag to your php artisan make:model
command:
php artisan make:model Post -mcf --actions
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Credits
License
The MIT License (MIT). Please see License File for more information.