7
๐ฅ Laravel can automatically notify you by email when a scheduled job fails
๐ก#Laravel Tip: Did you know that any commands you schedule in the console kernel can automatically email their output if something goes wrong.
๐ฅ This week's code tips for Laravel developers
A weekly thread ๐งต
7
๐ก#Laravel Tip: Did you know that any commands you schedule in the console kernel can automatically email their output if something goes wrong.
6
When you're counting related models in @laravelphp, opt for aggregates!
๐ Using the count() method on a collection of related models is a tad slower.
5
Not sure on the difference between "strtoupper" and "mb_strtoupper"? #PHP
4
๐ก Since @laravelphp v8.19, there is a ShouldBeEncrypted interface that jobs can implement. This encrypts the payload, for example, in case the properties hold sensitive data.
As of v8.25, this works for Listeners, Mailables, and Notifications as well ๐ซ
#Laravel #PHP #webdev https://twitter.com/pascalbaljet/status/1462711618329055232
3
A tiny tip about #laravel eloquent.
To retrieve the Query Builder after filtering the results: you can use ->toQuery()
.
The method internally use the first model of the collection and a whereKey
comparison on the Collection models.
2
๐ก#Laravel Tip: Here's a useful little helper for when you need to run some code, but don't really need to handle any exceptions it might generate.
1
To boost perceived speed in your @LaravelLivewire apps when loading data, make use of prefetching.
The .prefetch modifier tells Livewire to fetch the result in the background on hover, and then displays the result when the button is actually clicked โจ
We're writing a book, you can get it for free here. We're writing a book! Join the early access to get it for free.