Video Version of the Lesson
[Only for premium members]
[Only for premium members]
[Only for premium members]
Filament is installed in the existing Laravel project. Ideally, before Filament, you should have the database migrations/models/seeders, and then Filament would build the admin panels and forms for that data.
So, first, let's prepare a simple Laravel project.
So, I've created a new Laravel 12 project:
laravel new filament3-course
The wizard will ask for a starter kit. Choose None
.
All other choices are your personal preferences.
Next, we create a Model + Migration for one simple DB table "products", for now:
php artisan make:model Product -m
Migration
Schema::create('products', function (Blueprint $table) { $table->id(); $table->string('name'); $table->integer('price'); $table->timestamps();});
Next, we run those migrations:
php artisan migrate
In the Model, we add those columns as fillables:
app/Models/Product.php
class Product extends Model{ protected $fillable = ['name', 'price'];}
And that's it. Laravel project is ready. Now, let's install Filament to manage those products.
According to the official docs, there are two Terminal commands you need to run:
composer require filament/filament:"^3.3" -Wphp artisan filament:install --panels
You can run them one by one or together in one go.
The wizard will ask one question: what...