filamentphp/filament · error · LogicException

Please use the `FilamentAsset` facade to register scripts. S

Error message

Please use the `FilamentAsset` facade to register scripts. See the documentation - https://filamentphp.com/docs/support/assets#registering-javascript-files

What it means

Error "Please use the `FilamentAsset` facade to register scripts. See the documentation - https://filamentphp.com/docs/support/assets#registering-javascript-files" thrown in filamentphp/filament.

Source

Thrown at packages/panels/src/FilamentManager.php:1043

     * @deprecated Use the `resources()` method on the panel configuration instead.
     */
    public function registerResources(array $resources): void
    {
        try {
            $this->getDefaultPanel()->resources($resources);
        } catch (NoDefaultPanelSetException $exception) {
            throw new LogicException('Please use the `resources()` method on the panel configuration to register resources.');
        }
    }

    /**
     * @param  array<mixed>  $scripts
     *
     * @deprecated Register scripts using the `FilamentAsset` facade instead.
     */
    public function registerScripts(array $scripts, bool $shouldBeLoadedBeforeCoreScripts = false): void
    {
        throw new LogicException('Please use the `FilamentAsset` facade to register scripts. See the documentation - https://filamentphp.com/docs/support/assets#registering-javascript-files');
    }

    /**
     * @param  array<string, mixed>  $data
     *
     * @deprecated Register script data using the `FilamentAsset` facade instead.
     */
    public function registerScriptData(array $data): void
    {
        FilamentAsset::registerScriptData($data);
    }

    /**
     * @param  array<mixed>  $styles
     *
     * @deprecated Register styles using the `FilamentAsset` facade instead.
     */
    public function registerStyles(array $styles): void

View on GitHub (pinned to 53483fa934)

When it happens

Trigger: Thrown at packages/panels/src/FilamentManager.php:1043 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of filamentphp/filament@53483fa934 (2026-08-17). Data as JSON: /api/errors/ad0ea16472ad010b. Report an issue: GitHub.