How to fix Target class [AdminController] does not exist in Laravel

Hey there I learnig laravel I create a controller named “AdminController”
and add route in web.php Route::post('/auth','AdminController@index');
here is my controller class

<?php

namespace App\Http\Controllers;

use Illuminate\Http\Request;

class AdminController extends Controller
{
    public function index()
    {
        return 'Perfect!';
    }
}

But I’m getting an error

You trying to go to fast. Stop and think about what you are doing. Maybe even consider reading the docs.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.