Laravel Pro Tips
#routes #controllers #resource
Laravel tip 🔥 Instead of writing multiple resource controllers, you can register many resource controllers at once by passing an array to the resources method. #laravel #buildinpublic #coding
Hamza Ikram || Laravel Developer
#routes #controllers
#Laravel Tip ⚡ Instead of using the controller in each route, consider using a route controller group.
Sanjit Singh
#routes #controllers #redirects
🔥 Quick #Laravel Tip - Did you know that you can redirect() not only to a specific route/view but to a specific Controller and method as well, and pass data in the same way as you would do when returning a view?
Marian Pop 🇺🇦 Laravel Magazine
#routes #controllers #route groups
🔥 #Laravel Tip: If you’ve got a controller with a lot of methods in it, consider using route controller groups (new in V9) to save yourself some unnecessary typing.
Matt Kingshott
Laravel tip: if your routes have a lot of resource controllers, you can group them and call one Route::resources() instead of many single Route::resource() statements.
Povilas Korop | Laravel Courses Creator & Youtuber
💡Since #Laravel 8 you can group routes by Controller. It's very useful if you don't need every route for a resource just a few:
Martin Joo
Jan 12th, 2023
#routes #controllers #middleware
Laravel Middleware: Put in Routes, Controller, or Elsewhere? (4 Options)
If you have a Middleware, where you should use it: in the Routes file or in the Controller? Here are the FOUR options.