Magic methods are okay in the right context

We're reasonable about it

Joel Clermont
Joel Clermont

"Magic" methods and properties show up several places in Laravel, as well as third-party packages. They can make certain things easier and less verbose, but there is a trade off.

In the latest episode of the No Compromises podcast, Aaron and I discuss a few different contexts where we like and avoid magic accessors.

Listen Now (12 min)

And after listening, don't forget to subscribe to the podcast, so you don't miss future episodes.

Here to help,


P.S. Do you want our opinions on Laravel validation rules? We wrote a book on it. Enjoy!

Toss a coin in the jar if you found this helpful.
Want a tip like this in your inbox every weekday? Sign up below 👇🏼

Level up your Laravel skills!

Each 2-minute email has real-world advice you can use.