-
-
Save iradofurioso/96995eb8e40bae811e23c60d8361b7ef to your computer and use it in GitHub Desktop.
Laravel: Removendo o prefixo '/api/' da URL | Removing /api/ prefix from URL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//File: app\Providers\RouterServiceProvider.php | |
// Removing prefix line | removendo a linha de prefixo | |
//Mudar | Change | |
protected function mapApiRoutes() | |
{ | |
Route::prefix('api') | |
->middleware('api') | |
->namespace($this->namespace) | |
->group(base_path('routes/api.php')); | |
} | |
// para | to | |
protected function mapApiRoutes() | |
{ | |
Route::middleware('api') | |
->namespace($this->namespace) | |
->group(base_path('routes/api.php')); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment