return route in laravel controller code example
Example 1: laravel route controller
use App\Http\Controllers\UserController;
Route::get('user/{id}', [UserController::class, 'show']);
Example 2: Laravel route not calling function of controller
//in the terminal run
composer dump-autoload