An open API service indexing awesome lists of open source software.

https://github.com/webteractive/make-action

This Laravel package provides a php artisan make:action command to quickly scaffold "Action" classes.
https://github.com/webteractive/make-action

Last synced: 7 months ago
JSON representation

This Laravel package provides a php artisan make:action command to quickly scaffold "Action" classes.

Awesome Lists containing this project

README

          

# Laravel make:action Command

This Laravel package provides a `php artisan make:action` command to quickly scaffold "Action" classes. This encourages organized and reusable business logic.

## Installation

You can install the package via composer:

```bash
composer require webteractive/make-action
```

You can publish the config file with:

```bash
php artisan vendor:publish --tag="make-action-config"
```

This is the contents of the published config file:

```php
// config for Webteractive/MakeAction
return [
'method_name' => 'handle',
];
```

## Usage

To create a new action class, run the `make:action` Artisan command:

```bash
php artisan make:action CreateNewUser
```

This will create a new action class at `app/Actions/CreateNewUser.php`:

```php
'execute',
];
```

## Testing

```bash
composer test
```

## Changelog

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

## Contributing

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

## Security Vulnerabilities

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

## Credits

- [Glen Bangkila](https://github.com/)
- [All Contributors](../../contributors)

## License

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.