I have started working on Laravel recently and I have installed Laravel Framework 8.5.0.
Following is my controller "UserController.php"
namespace App\Http\Controllers;
use Illuminate\Http\Request;
class UserController extends Controller
{
//
public function index(){
return "hello world";
}
}
and here's my web.php in routes
Route::get('/users', 'UserController@index');
When ever I try accessing http://127.0.0.1:8000/users, It just hits me with following error
Illuminate\Contracts\Container\BindingResolutionException
Target class [UserController] does not exist.