Open sawirricardo opened 1 year ago
@sawirricardo I just tried this in a fresh project with Filament but I don't seem to get the error you described. Is there anything you can think off that will help me reproduce the error?
Hem, How about this?
composer create-project laravel/laravel test;
composer require filamentphp/filament;
composer require spatie/laravel-blade-comments --dev;
php artisan migrate:fresh --seed;
Then try to access https://example.com/admin (will be redirected to login) and see the browser output (notice the SupportAlpine.js, addDollarSignWire error)
Here's mine
The only way is to.... remove this package...
And even then will require to php artisan optimize:clear
Can confirm, even disabling the blade comments package in config doesn't help.
@sawirricardo thank you for the extra info! I'm now also able to replicate it.
I'm still not entirely sure what's exactly going wrong. The problem seems to be more specific the combination of Filament and the AnonymousBladeComponentCommenter from our package but I haven't been able to pinpoint the exact component that is causing the proble.
The solution could be as simple as refining the regex for this commenter, but I don't really have time to go all the way down through the Filament rabit hole. If someone has time to find the exact component that is causing the problem I'de be happy to have an other look.
For now I would advice to publish the config file for this package and comment out the AnonymousBladeComponentCommenter. This should still give you blade comments for all other types of components while resolving the issue you are having.
What happened?
After installation, I noticed that in the browser console it outputs an error of wireEl is undefined.
How to reproduce the bug
Just install this package in a livewire project, preferable with Filament's admin package. And see the browser console.
Then go through the browser console and see the error
Package Version
1.0.1
PHP Version
8.2.0
Laravel Version
10.13.0
Which operating systems does with happen with?
macOS
Notes
Filament ......................................................
Packages ...... filament, forms, notifications, support, tables
Version .............................................. v2.17.44
Views ..................................... PUBLISHED: filament