When I try php artisan serve command at my terminal it gives below error.Can any body help me to fix this issue?
ErrorException The use statement with non-compound name 'App' has no effect
When I try php artisan serve command at my terminal it gives below error.Can any body help me to fix this issue?
ErrorException The use statement with non-compound name 'App' has no effect
remove
use App;
from your route.php file, it will work for sure. Thanks.
I hereby post the answer for my own question as I found answer for this and hope this may helpful others in future.
Before : I just used 'use App' only at routes.php Now : When use 'use App\Http\Controllers' problem solved.
Probably you add 'use App;' in some of your Laravel files, and artisan is parsing the line as an error. To know which line/file is the error, go to the log file (storage/logs/) and check it out. Then remove that line from the file.