TLDR;
I have a problem while including my package with livewire into a project which has livewire.
What seems to be the problem:
Whenever I’m trying to install my package that uses Livewire into an application that has already Livewire as a requirement, it breaks the application.
Steps to Reproduce:
- Create a new application with Laravel Jetstream, register, login and check the dashboard.
- Include a package that actively uses Livewire.
- In my case, I get the error:
Call to undefined method Facade\Ignition\Views\Engines\CompilerEngine::startLivewireRendering() (View: /Users/belli/code/testj/resources/views/layouts/app.blade.php)
If I remove the package, it works again.
Are you using the latest version of Livewire:
yes, in both cases.
Do you have any screenshots or code examples:
I define Livewire like this in my package:
"extra": {
"laravel": {
"providers": [
"alessandrobelli\\Lingua\\LinguaServiceProvider",
"Livewire\\LivewireServiceProvider"
],
"aliases": {
"Livewire": "Livewire\\LivewireServiceProvider",
"Lingua": "alessandrobelli\\Lingua\\LinguaFacade"
}
}
}
Otherwise I get the error Illuminate\Contracts\Container\BindingResolutionException : Target class [livewire] does not exist.
discussed here.
I really think that the package development page needs improvement. Maybe I will write something after I can solve this.