
In plain words
A controller is a class (a named bundle of code) that holds the functions your routes call. Instead of writing all the code inside the routes file, you keep routes short and put the work in controllers, one per topic: LessonController, OrderController.
php artisan make:controller LessonController

Found this useful?
Every lesson stays free. Tap the thumbs up so we know what works, or say thanks with a soda or a coffee: it pays for hosting and new lessons.


