#issues when installing the panel

17 messages · Page 1 of 1 (latest)

olive iron
#

What I am trying to do: I am trying to install the admin panel

What I did:
i ran: composer require filament/filament
php artisan filament:install --panels

My issue/the error: when running php artisan filament:install --panels
it asks for and admin id. when i provide one it finished the installation but gives an error in my files and i cant acces the panel

Code: In providers.php line 5:

syntax error, unexpected token "", expecting "]"

return [
App\Providers\AppServiceProvider::class,
App\Providers\Filament\1PanelProvider::class,
];

carmine canyon
#

Possibly caused by the 1 in the PanelProvider don't think classes support numbers

olive iron
#

yeah i saw that but it does it automaticly when it asks for an id?

carmine canyon
#

Did you write 1 for the ID per chance? ID means the name of the panel i.e. 'client' or 'admin'

olive iron
#

yes

#

wasnt i supposed to?

carmine canyon
#

No...

#

It\s supposed to be 'client' or 'admin' for instance

olive iron
#

it says nothing about that in de documentation

#

but ill try it now

carmine canyon
#

It doesn't need too, it says in the generation:

Panel ID i.e. 'admin' or similar I am sure, I'll check the install command now

#

Interesting you were allowed to start with an integer

        validate: fn (string $value) => match (true) {
            preg_match('/^[a-zA-Z].*/', $value) !== false => null,
            default => 'The ID must start with a letter, and not a number or special character.',
        },

shows it shouldn't have been allowed.

olive iron
#

it worked thank you

#

but i would put it in the documentation so that others wont get confused

carmine canyon
#

It shouldn't ever happen because of the validator so surpised it worked for you

olive iron
#

haha

#

alr il work on my panel now thanks again!