Summer sale! Save 50% on access to our entire library of courses.Join here →

Articles

Showing 10 posts
May 22nd, 2024

Pagination with Inertia and Vue

In this article, you'll learn how to add pagination to your Inertia apps with a simple, custom, re-usable pagination component.

Author
Alex Garrett-Smith
Vue
Inertia
Laravel
May 21st, 2024

How to Use Casts Inside a Laravel Trait

If you move over some functionality to a trait in Laravel that requires casts to be added as part of the trait's functionality, this won't merge by default.

Author
Alex Garrett-Smith
Laravel
Eloquent
May 19th, 2024

Eloquent Events on Pivot Tables

I recently needed to listen to events on a pivot table within the Codecourse codebase. When a user resets progress for a course, and all the episodes they've completed are detached, episode progress (stored in Redis) should be removed.

Author
Alex Garrett-Smith
Laravel
Eloquent
May 18th, 2024

Using the Booted Method Inside Traits in Laravel

Extracting some functionality to a trait but need to use the static booted method within that trait? Here's how.

Author
Alex Garrett-Smith
Eloquent
Laravel
May 17th, 2024

Disable Global Scopes in Laravel Nova

If you're using global scopes in Laravel, these will likely affect your admin panel. Here's how to remove them.

Author
Alex Garrett-Smith
Laravel
May 7th, 2024

Your Guide to Every Official Laravel Package and Service

The Laravel Ecosystem is big. So big that when you start working with it, it's sometimes difficult to know which first-party packages are available, and which ones to reach for.

Author
Alex Garrett-Smith
Laravel
April 30th, 2024

What Codecourse Uses

So what goes into running a profitable educational screencast company for developers? Here's everything I use.

Author
Alex Garrett-Smith
Business
April 23rd, 2024

Calling Livewire methods from Alpine.js

Because Livewire and Alpine.js are so tightly linked, calling a Livewire method from your Alpine components is a breeze.

Author
Alex Garrett-Smith
Livewire
Alpine.js
April 22nd, 2024

Resetting Laravel Collection Keys After Filtering

I recently filtered a Laravel collection that was due to be output as JSON. To my surprise, it didn't work as intended. Here's what happened, and how to resolve it!

Author
Alex Garrett-Smith
Laravel
April 19th, 2024

How to disable Laravel Scout for Nova Resources

For whatever reason, you may need to disable Laravel Nova automatically using Scout when searching. Here's how.

Author
Alex Garrett-Smith
Laravel

Tags