Download the PHP package themsaid/laravel-routes-publisher without Composer
On this page you can find all versions of the php package themsaid/laravel-routes-publisher. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download themsaid/laravel-routes-publisher
More information about themsaid/laravel-routes-publisher
Files in themsaid/laravel-routes-publisher
Package laravel-routes-publisher
Short Description A command to replace deprecated Route::controller with explicit routes.
License MIT
Homepage https://github.com/themsaid/laravel-routes-publisher
Informations about the package laravel-routes-publisher
Laravel Routes Publisher
A command to replace deprecated Route::controller()
and Route::controllers()
with explicit routes.
In laravel 5.3 implicit controller routes will be removed from the framework, the functionality will likely be extracted into a separate package, however if you'd like to make the move and start using explicit routes this package will help you.
Installation
Step 1:
Step 2:
Include the following command in your $commands
attribute of app/Console/Kernel.php
:
Usage
Run the following command:
After the command is done, two new files will be generated in your app/Http
directory:
Replace the content of your routes.php
file with that of routes.php.generated
, knowing that if anything went wrong a backup
of your original routes.php
's content will be available in routes.php.backup
.
This package assumes the following:
- Your
routes.php
doesn't contain any PHP syntax errors. - Your
routes.php
file is located inapp\Http\routes.php
with the exact name. - Your
routes.php
files doesn't include any other file usinginclude
orrequire
. - Your Application namespace is correctly registered in the psr-4 section of
composer.json
.
Problems?
I tried hard to cover different syntax and file formatting in this package, however if you found any problems while using the package please open a new issue.