Types de contrôleur à Laravel
-types of controller:
-basic controller
-php artisan make:controller basicController
-Route: Route::get('about',[basicController::class,'about']);
-single action controller (handle single action)
public function __invoke(){//inbuilt}
-php artisan make:controller singleActionController --invokable
-Route::get('course',singleActionController::class); //it will invoke only one function
-resource controller (CRUD functions)
-Route::resource('photo',photoController::class); //invoke index function
kinjal suryavanshi