๐ Top Laravel 12 Features Youโll Love
๐น 1. Modern Starter Kits
React (with TypeScript + shadcn/ui), Vue (Inertia), and Livewire (with Flux/Volt) โ fully tailored for modern frontend stacks.
laravel new project-name --kit=react
๐น 2. Collection & String Enhancements
๐ก containsOneItem() โ No more manual count checks!
collect([5])->containsOneItem(); // true
collect([1, 2])->containsOneItem(); // false
๐ก Str::reverse()
use Illuminate\Support\Str;
echo Str::reverse('Laravel'); // "levaraL"
๐ก ifEmpty() / unlessEmpty()
collect([])->ifEmpty(fn() => logger('No items')); // logs 'No items'
๐น 3. Built-in WorkOS AuthKit
Add Passkey, SSO, or Social Login using a Laravel-native integration with WorkOS.
composer require laravel/authkit
php artisan authkit:install
โก๏ธ Great for teams needing secure onboarding without reinventing login flows.
๐น 4. Anonymous Migrations by Default
No more migration class name collisions ๐
return new class extends Migration {
public function up(): void {
Schema::create('posts', function (Blueprint $table) {
$table->id();
$table->string('title');
});
}
};
And clean conditional broadcasting:
โ๏ธ Bonus:
Laravel 12 supports PHP 8.2/8.3, works with older tools like Fortify, and is smoother to upgrade with very few breaking changes.
๐ง What I like:
โ
Laravel is focusing more on DX (Developer Experience)
โ
Auth is becoming cleaner + scalable
โ
Tools like debug()->suggest() (AI powered!)
๐ฌ What do you think?
Are you upgrading to Laravel 12 or waiting for the next LTS?
Drop your thoughts! ๐
Top comments (0)