F
Filament3mo ago
Neamix

Add script to a page

How can i added script to a certain page i dont want to add it globally only a script for one page
Solution:
use Filament\Support\Facades\FilamentView; use Filament\View\PanelsRenderHook; use Illuminate\Support\Facades\Blade; FilamentView::registerRenderHook(...
Jump to solution
1 Reply
Solution
Neamix
Neamix3mo ago
use Filament\Support\Facades\FilamentView; use Filament\View\PanelsRenderHook; use Illuminate\Support\Facades\Blade; FilamentView::registerRenderHook( PanelsRenderHook::PAGE_START, fn (): View => view('warning-banner'), scopes: \App\Filament\Resources\UserResource\Pages\EditUser::class, );
Want results from more Discord servers?
Add your server