Closed SOG-web closed 1 week ago
This model does not exists. So, you can't iterate that way.
<x-collapse :name="'group'.$index">
The below code works, because the model now it is an array that hold each accordion state. All you have to do is to figure out a way to fill it with as many "groups" you need. The name does not matter.
public array $groups = ['group1', 'group2', 'group3'];
<!-- The only thing is matter here is the key `$k` -->
@foreach($groups as $k => $g)
<x-accordion wire:model="group[{{ $k }}]" >
....
@endforeach
Thanks so much, it later worked, but I had to remove flowbite lib. Flowbite and daisyui are having some conflict somehow
maryUI version
1.33.2
daisyUI version
4.11.1
Livewire version
3.5.1
What browsers are affected?
Firefox, Chrome, Safari, Microsoft Edge
What happened?
accordion not expanding and collapsing
HTML/Blade