How to create route name in Laravel 5?
You can create this by "name" attribute in your routes/web.php
.
Below is an example
Route::get('contact-us', '[email protected]')->name('contact');
In this example our route name is contact
. You can call this route URL with this route name also.
<a href="{{route('contact')}}"> Go to Contact page </a>
BY Best Interview Question ON 06 Mar 2019