laravel target class does not exist
snippet in php

Target class [] does not exist.

user526

composer dump-autoload

Target class [Controller] does not exist.

user6198

//accessing any function in the controller (this is web.php file)
use App\Http\Controllers\PostsController;

Route::get('/post', 'App\Http\Controllers\PostsController@index');

Target class [PlayerController] does not exist.

user9215

//add controller path
Route::get('/players', 'App\Http\Controllers\PlayerController@index');

laravel target class does not exist

user6277

Uncomment this line in app>>provider>>RouteServiceProvider.php file
// protected $namespace = 'App\\Http\\Controllers';

Target class [Controller] does not exist.

user8084


Route::get('/users', [UserController::class, 'index']);