jdw5/artisan-assemble
最新稳定版本:v0.2.4
Composer 安装命令:
composer require jdw5/artisan-assemble
包简介
Custom Laravel Artisan commands to reduce boilerplate
README 文档
README
Custom stubs and make commands for Laravel's artisan CLI.
Installation
composer require --dev jdw5/artisan-assemble
Once installed, you should publish the configuration file to customise your stubs by publishing them. This is also required to change the default page/modal stubs to use your own components - and change from Vue to react.
php artisan vendor:publish --tag=artisan-assemble
In the published config/artisan-assemble.php file, you can select the file extension that should be used for your page/modal routes. By default, this is set to .vue but you can change this to whatever you require - just be sure to update the stubs accordingly.
Available Commands
make:endpoint {name}
This creates a new single action controller and request pair with opinionated namespacing.
Example usage:
php artisan make:controller User/Item/ItemStore
This will create two files: App/Http/Controllers/User/Item/ItemStoreController.php and App/Http/Requests/User/Item/ItemStoreRequest.php.
You can pass additional options to endpoint command.
-por--pagewill additionally create a page at the given namespace.-mor--modalwill additionally create a modal at the given namespace.-for--formwill use the form variant of the page/modal component if they are specified
make:page {name}
This will create a new page using your specified or the default stub at the given namespace.
make:modal {name}
This will create a new modal using your specified or the default stub at the given namespace.
make:hash {name}
This is a shorthand command to create hash casts for your models to obfuscate IDs (usually).
make:enum {name}
This will create a new enum class at the given namespace within the App\Enums directory.
make:filter {name}
This will create a new filter class at the given namespace within the App\Filters directory. Filters are used for pipelining operations, particularly for handling query parameters.
统计信息
- 总下载量: 13
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: mit
- 更新时间: 2024-02-11