MENU

Fun & Interesting

5 tips for supercharged Laravel Eloquent queries

Andrew Schmelyun 69,362 lượt xem 4 years ago
Video Not Working? Fix It Now

In this 16 minute video, I'll show you 5 simple tips and tricks that you can use to enhance your Laravel Eloquent queries, saving time and helping to clean up your code.

Join my newsletter for weekly tips on Laravel + Docker: https://aschmelyun.substack.com

You'll learn:

- How to build a query on the fly using conditionals
- How to use whereHas to filter out relationships by nested values
- How to create a dynamic attribute and automatically inject it in returned models

Follow me on Twitter! https://twitter.com/aschmelyun

Comment