laravel / folio

Page based routing for Laravel.
MIT License
568 stars 46 forks source link

[1.x] Adds stub option to make command #136

Closed inmanturbo closed 6 months ago

inmanturbo commented 6 months ago

Depends on https://github.com/laravel/framework/pull/50709

Usage:

Supports passing either a named stub, or full path to a stub as an option

php artisan make:folio "todos/index" --stub="folio-index"

will find and use base_path('stubs/folio-index.stub') if it exists.

php artisan make:folio "todos/index" \
  --stub="/home/taylor/stubs/talks/laracon/2024/us/folio/todos-index.stub"

will find and use /home/taylor/stubs/talks/laracon/2024/us/folio/todos-index.stub if it exists.

If it cannot find a stub under the name or path, it will ignore the option altogether and behave as it always has.

github-actions[bot] commented 6 months ago

Thanks for submitting a PR!

Note that draft PR's are not reviewed. If you would like a review, please mark your pull request as ready for review in the GitHub user interface.

Pull requests that are abandoned in draft may be closed due to inactivity.