Piggybacking off the last 🔥 tip, most Blade templates simply use the `if` directive.
However, there are so many more Blade directives available. These are not only more expressive, but often streamline the code.
Here's a side-by-side comparison: https://t.co/Z2Edmf8kDO
Did you know that you can use the DB facade to create a Partition Metric in Laravel Nova to breakdown email domains? #ProTip https://t.co/eTCoadCWFW
🔥 Have you heard of the 'onbeforeunload' event?
When a user clicks back, you can use onbeforeunload to prompt the user. Returning a value will change the default message in the popup.
Great for sites that handle a lot of data input!
👨🔧 Finally got sick of seeing this error when pushing new branches. Turns out a simple config option allows `git push` to do the heavy lifting. Why is this not the default?!
Do yourself a favour 👇 https://t.co/hBJa5JJbIm
#Laravel tip of the day: how to calculate the sum of ALL records, if you only have a PAGINATED collection? You calculate sum BEFORE the pagination, but from the same query. https://t.co/lpPps70Vqs
When registering routes, you may limit the possible values for a route parameter. In this way you may change your response based on a valid parameter, having an expressive route and not a Query string parameter. @laravelphp @laravelnews https://t.co/3e1AzXVKCu
TIL you can center things in CSS grid with a single property now