I have a Laravel Spark application and I would like to use the first two parameters in the route for the team and the project, with exceptions like about_us, settings, api, etc.
I set up my routes similar to:
Route::pattern('team', '[a-zA-Z0-9-]+'); Route::pattern('project', '[a-zA-Z0-9-]+'); Route::get('/home', ' HomeController@show '); Route::group(['prefix' => '{team}'], function () { Route::get('/', ' TeamController@dashboard '); Route::group(['prefix' => '{project}'], function () { Route::get('/', ' ProjectController@dashboard '); ...
I'm struggling to do one of two things. Or, excluding values ββsuch as "api", "settings", etc. From the template {team}; or run Laravel Spark routes in front of my web routes so I can make sure all valid routes are checked before all / {command}.
Any ideas would be appreciated!
Kurucu
source share