tibian / route-organizer
Route Organizer for Laravel
Installs: 199
Dependents: 0
Suggesters: 0
Security: 0
Stars: 4
Watchers: 1
Forks: 2
Open Issues: 0
Type:project
Requires
- php: >=5.5.9
- symfony/finder: ^v3.1
This package is auto-updated.
Last update: 2022-09-29 01:46:34 UTC
README
Route Organizer for Laravel is simple route solution to organize your Routes.
Install
Require this package with composer using the following command
composer require tibian/route-organizer
Usage
Open App\Providers\RouteServiceProvider
on method mapWebRoutes
/ mapApiRoutes
define new Routes for the Application.
new RouteOrganizer('routes/web'); new RouteOrganizer('routes/api');
Example for web routes
Note: The same you can do of course and for the api Routes
protected function mapWebRoutes() { Route::group([ 'middleware' => 'web', 'namespace' => $this->namespace, ], function ($router) { new RouteOrganizer('routes/web'); // new Web Routes for the Application require base_path('routes/web.php'); }); }
Now you can Organize your Routes as you wish.
- The following example is the best if you use PHPStorm and Laravel Plugin
/path/to/laravel/routes