The next step is extremely important. The Laravel application must process the annotations. For this chore, Artisan is used to scan the routes.
The following command is used to scan the routes. The output will be Routes scanned!
as shown here:
$ php artisan route:scan Routes scanned!
The results of this scan will produce a file named routes.scanned.php
in the storage/framework
directory.
The following code writes to storage/framework/routes.scanned.php
file:
$router->get('search-accommodation', [ 'uses' => 'MyCompanyHttpControllersAccommodationsController@search', 'as' => NULL, 'middleware' => [], 'where' => [], 'domain' => NULL, ]);