Please, please, please - use Eloquent attribute Casting
Why Laravel Eloquent attribute casting matters, how it simplifies your models, and how proper casting leads to cleaner, safer, and more predictable code.
Why Laravel Eloquent attribute casting matters, how it simplifies your models, and how proper casting leads to cleaner, safer, and more predictable code.
A practical walk-through of using PHPStan static analysis on a legacy codebase, tips on setup, rule levels, and error patterns encountered with Larastan.
A practical refactoring technique using lookup tables to replace condition-heavy logic, making PHP code easier to read, extend, and maintain.
Practical tips and lessons learned from building applications with the VILT stack, covering Vue.js, Inertia.js, Laravel, and Tailwind CSS.
Practical advice for writing cleaner, more readable PHP code, focusing on simplicity, consistency, and real-world maintainability over clever abstractions.
A deeper look at working with PHP backed enums and Laravel collections, including transforming enum values into arrays and appending custom attributes.
Learn how to combine PHP backed enums with Laravel collections to build more expressive, reusable, and maintainable enum-based logic.