Livewire only supports one HTML element per component. Multiple root elements detected for component
Error message I get:
Livewire only supports one HTML element per component. Multiple root elements detected for component: [auth.forgot-password-page]
11 Replies
Yes that is correct.
Yes but what is the solution?
How do I paste the code in here so it is in a container?
You didn't ask that... you posted a statement.
The answer is to have one primary div
Stack Overflow
Livewire - Multiple root elements detected
I'm creating a table, whose rows are wrapped inside a livewire component
<div class="card">
<div class="card-body">
<table class="table table-hover
But I have wrapped everything in one div
<!-- Form Group -->
is a html element.
no it is still not resolved
Then you need to debug it and workout where you are causing this.
The above won't cause it.
Not able to solve it
I have the same issue. Right after installing the filament according to the guide, I went to the login page and it triggered the error.
"Livewire only supports one HTML element per component. Multiple root elements detected for component: [filament.pages.auth.login]"
Before installing the filament, I already had my livewire running for my listing and it works.
sounds like you have something injecting something if it's an existing app