SKILL.md
Filament Development
When to use this skill
Use this skill when you are working on anything related to Filament v3, including Resources, Widgets, Pages, and custom components.
Core Principles
- The Filament Way: Use
php artisan make:filament-resource and similar commands.
- Fluent Interface: Use method chaining for forms and tables.
- Search Docs First: Use the
search-docs tool with filament/filament for any component options.
Resources
Create resources using:
php artisan make:filament-resource {Name} --generate
Forms
Define forms in the form() method:
public static function form(Form $form): Form
{
return $form->schema([
TextInput::make('name')->required(),
Select::make('status')->options([...]),
]);
}
Tables
Define tables in the table() method:
public static function table(Table $table): Table
{
return $table->columns([
TextColumn::make('name')->searchable(),
IconColumn::make('is_active')->boolean(),
]);
}
Widgets
Create widgets using:
php artisan make:filament-widget {Name}