Laravel 13.6, weekly updates and tip
Laravel 13.6
Couple big features this week brings us Laravel 13.6. Here are the highlights:
- Allow
#[Table]on child to override parent in #59701 - Add debounceable queued jobs in #59507
- Support JSON responses for the built-in health route in #59710
- Support named credential providers for SQS queue connections in #59733
- Allow database assertions to accept arrays in #59752
- Introduce
JsonFormatterin #59756 - Add support for Cloudflare Email Service in #59735
- Add
prefersJsonResponses()to the application builder in #59753
You may review the full branch diff on GitHub for a complete list of changes.
Weekly Journal
Last week I made some updates to the Pest Converter. This is something I livestreamed building a few years ago. Although Pest actually released their own internal conversion tool, this still gets a few runs. However, it had not been updated to reflect the latest versions and features of Pest.
I also worked with Ana to finally merge a big PR to refactor all of the "issue dialogs" that appear on the Shift dashboard. Previously each Shift included each of its potential dialogs (up to 7). This made the page a bit heavy/chatty. Instead, the dialog boxes are now shared and the Shift loads in the appropriate content (via Livewire).
I still need to work on the Tests Generator. But honestly, even after a vacation, I have not been very focused. Some of it is life, but some of it is AI. I use AI to write a majority of my code now. And while it has made me efficient, it has also made me lazy. I talked about this before. I used to pride myself my ability to plug in. To focus. But now AI does my work in minutes. In fact, most of those minutes I'm not doing anything. Just waiting for it to be done. I'm still adjusting to that workflow.
Weekly Tip
A user reported an issue when the Laravel 13.x Shift converted to the new #[Authorize] attribute. It accepts a second parameter for the name. While that sounds straightforward, there is a bit of a nuance.
Underneath this attribute converts to the string based can: middleware. That middleware accepts the route parameter name. But the #[Authorize] attribute is added at the controller level.
Going deeper, route model binding uses snake_case, but you typically use camelCase for your controller parameters.
For the most part, Laravel automagically wires this up. But that's not the case for the #[Authorize] attribute. That second parameter is strictly the route parameter name.
In the end, this really only matters for compound names (e.g. user_group, order_item). But still a little nuance to keep in the back of your mind.