Video wird geladen...

Video konnte nicht geladen werden

Zur Startseite

Running into a really weird Livewire issue — anyone have a clue where I can dig a bit deeper for a solution?

11,195 Aufrufe • vor 1 Jahr •via X (Twitter)

10 Kommentare

Profilbild von Jason Beggs
Jason Beggsvor 1 Jahr

@LaravelLivewire Try changing :$key to wire:key="$key"

Profilbild von Sander Muller
Sander Mullervor 1 Jahr

@LaravelLivewire spam wire:key on places until it works

Profilbild von heeetok👁️‍🗨️
heeetok👁️‍🗨️vor 1 Jahr

@LaravelLivewire Try Wire:replace on the inside div I actually run into this exact problem this morning.

Profilbild von Lars Klopstra ⬙
Lars Klopstra ⬙vor 1 Jahr

@LaravelLivewire Does the cart item have a single root element?

Profilbild von Jack McDade
Jack McDadevor 1 Jahr

@LaravelLivewire Indeed it does

Profilbild von Doug Sisk
Doug Siskvor 1 Jahr

Try explicitly defining your key perhaps? :key="$item->id"

Profilbild von Jack McDade
Jack McDadevor 1 Jahr

Good idea but nope, same problem.

Profilbild von Edwin Encomienda
Edwin Encomiendavor 1 Jahr

@LaravelLivewire maybe you missed some closing tags

Profilbild von Josh Larson
Josh Larsonvor 1 Jahr

@LaravelLivewire wire:key on the nested/outer div might do it. The DOM diffing algorithm gets confused when encountering multiple sibling divs with similar or no attributes. I’ve been there btw and it’s not a fun place to be lol

Profilbild von Leaguewell, Inc
Leaguewell, Incvor 1 Jahr

@LaravelLivewire For better readability and to ensure no conflict, I would change $key=>$value to $name => $value or something else. Then I would add wire:key.

Ähnliche Videos