laravel routename code example
Example 1: laravel get route
Route::get('foo', function () {
return 'Hello World';
});
Example 2: laravel is route name
// Check if route is ***
Request::route()->named("YourRouteNameView")
Route::get('foo', function () {
return 'Hello World';
});
// Check if route is ***
Request::route()->named("YourRouteNameView")