🔥 An important consideration when working with @laravelphp's environment and config tooling that bit me.
Keys that exist in your `.env` file with no value will not fallback to the `env()` helper's default value.
To achieve the desired outcome, use null coalescing instead. https://t.co/qptuGEPzMN
🔥 Ever wondered how to set active states on links in an @inertiajs app? It's actually really easy to do!
💁♂️ Simply do string comparisons against the `page.url` or `page.component` properties. You can do exact matches, or "startsWith" checks, or even regular expressions! https://t.co/Gc3I917bVJ
TIL about the Eloquent reorder() method, which clears previously set orderBy clauses 🙌 https://t.co/ptl4EmCfSV
You can then use that in Intl.NumberFormat to trim off .00 when displaying prices of whole dollar amounts https://t.co/t59fXDJrAD
How Spotify makes text on images more readable: a CSS linear-gradient overlay. More common these days, but still an effective technique for better color contrast. https://t.co/tZDlwLRx3G
If you want to save an Eloquent model without triggering Eloquent Events use the method saveQuietly()
Lifesaver on model observers when you don't want to recursively trigger its own events (ending in an infinite loop)
🚀 Laravel Performance Tip:
To avoid memory leaks in queue workers, it's often a good practice to restart your workers at regular intervals.
This is from @themsaid's blog. Original post: https://t.co/81gijq6PLT https://t.co/LasZo7eAIM
🔥 Don't forget when Route Model Binding in @laravelphp, you can customize the column Laravel uses to find the model in your route definition now! It's the little details that make Laravel so awesome. https://t.co/qvb63xobj5
✨ Composer comes with an `InstalledVersions` class that lets you check dependencies at runtime. #php #laravel https://t.co/U6THJxjAdA