Eloquent Performance Pattern - notes
use laravel debugbar
composer require barryvdh/laravel-debugbar --dev
use index to make it faster
// everything in column field needs to be indexed
order by {field}, where {field} = 1
do not use *
// *
User::query()
->with('author')
->latest('published_at')
->get()
->groupBy(fn($post) => $post->published_at->year)