So I went to read up on some Laravel documentation regarding Homestead because you know, Docker on Mac, arghhh, well that is a story for another day. Anyway, Laravel 9 is out and one of the features that stood out for me was the support for generic types. If you do not know what these are, there is a great article by Ondřej Mirtes regarding them https://phpstan.org/blog/generics-in-php-using-phpdocs. What does this have to do with Laravel?

Consider the code below, I have been using generic type hinting for a while in my code, more in a documentation capacity.
Newsletter

Get the latest Laravel/PHP jobs, events and curated articles straight to your inbox, once a week

Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge. Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge.
Fathom Analytics | Fast, simple and privacy-focused website analytics. Fathom Analytics | Fast, simple and privacy-focused website analytics.
Shirts painstakingly handcrafted by under-caffeinated developers. Shirts painstakingly handcrafted by under-caffeinated developers.
Community Partners