Skip to content

Commit 2c45b7e

Browse files
committed
try this
1 parent c1932aa commit 2c45b7e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packages/svelte/src/internal/client/dom/elements/attributes.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,10 @@ export function set_attributes(element, prev, next, css_hash, skip_warning = fal
448448
}
449449

450450
for (let symbol of Object.getOwnPropertySymbols(next)) {
451-
if (symbol.description === ATTACHMENT_KEY && (prev == undefined || !(symbol in prev))) {
451+
if (
452+
symbol.description === ATTACHMENT_KEY &&
453+
(prev == undefined || !(symbol in prev) || prev[symbol] !== next[symbol])
454+
) {
452455
attach(element, () => next[symbol]);
453456
}
454457
}

0 commit comments

Comments
 (0)