Tips and tricks to help you get the most out of your Laravel App Service Provider.

Inline CSS from file

19 min read
How to inline a CSS from a file in a Laravel blade template.

Show Git Info in PHP

10 min read
How to show the current Git branch and commit hash in a PHP application
Using User ID as API tokens for local development

How to implement social login in Laravel

7 min read
We will be using the following Laravel environment:
Broadcast events over websockets using Soketi with Laravel Homestead on Windows.

Debugging

5 min read
    How to debug anything.

    Extend Container Bindings

    3 min read
    How to build upon existing container values.

    Fail Validation

    2 min read
    Throw validation errors anywhere.

    Laravel gmail setup

    1 min read
    A quick tip to show how to configure gmail for laravel.

    Laravel mail config

    12 min read
    A quick guide on configuring mail in Laravel.

    Laravel mail testing

    5 min read
    A snippet to show how to assert against mailable properties in feature tests.

    419 page expired in tests

    4 min read
    Clear you cache in your testing/development environment to prevent csrf verification errors.

    Axios intercept

    2 min read
    A snippet to intercept axios to view requet details.

    Blade Component With JavaScript

    4 min read
    A simple but powerful way ensure a blade component has all the scripts needed to render the view in one file.

    Cross Join With Keys

    19 min read
    Use cross join to generate combinations of associative arrays.

    Homestead PHP-FPM Aliases

    10 min read
    Create your own bash alias to change Homestead's PHP-FPM settings per site.

    Laravel Pipelines

    27 min read
    Use pipeline classes run steps in sequence with an object oriented approach.

    Laravel redis cache tips

    19 min read
    Clearing the redis cache in Laravel apps.

    Local composer repositories

    13 min read
    Use local versions of packages in demo applications during development.

    Moving apps across AWS accounts

    1 min read
    A twitter tip from Claudio Dekker and Zubair Moshin about migrating AWS apps across accounts.

    No scrollbar css

    5 min read
    Hide the scrollbar!

    PHP 8 Match

    6 min read
    A couple of examples using PHP 8 match function.

    Pivot queries

    15 min read
    How to query additional attributes on pivot tables.

    Laravel polymorphic searching

    3 min read
    Filter by parent polymorphic models in Laravel apps.

    Qualify column

    7 min read
    Easily prepend your columns with the table name.

    Query Builder Classes

    14 min read
    Replace local query scopes with dedicated query builder classes.

    Queue cheatsheet

    4 min read
    Reference Laravel queue commands and configuration options.

    Retry helper

    5 min read
    Attempt to execute a callback until it succeeds or the maximum retry threshold is met and exception is thrown.

    Route functions cheatsheet

    32 min read
    A cheatsheet for request and route functions in Laravel applications.

    DateTime Formats

    42 min read
    Everything you need to know about date/time in Laravel.

    Inertia hot reload with Laravel mix

    5 min read
    How to use hot module replacement with Laravel mix and Inertia.js