Skip to content

Commit 65f5970

Browse files
committed
WIP
1 parent a168ecd commit 65f5970

File tree

1 file changed

+16
-0
lines changed
  • packages/svelte/src/internal/client/dom/blocks

1 file changed

+16
-0
lines changed

packages/svelte/src/internal/client/dom/blocks/branches.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,22 @@ export class BranchManager {
114114

115115
// TODO in the no-defer case, we could skip the offscreen step
116116
if (should_defer_append()) {
117+
for (const [k, effect] of this.#onscreen) {
118+
if (k === key) {
119+
batch.skipped_effects.delete(effect);
120+
} else {
121+
batch.skipped_effects.add(effect);
122+
}
123+
}
124+
125+
for (const [k, branch] of this.#offscreen) {
126+
if (k === key) {
127+
batch.skipped_effects.delete(branch.effect);
128+
} else {
129+
batch.skipped_effects.add(branch.effect);
130+
}
131+
}
132+
117133
batch.add_callback(this.#commit);
118134
} else {
119135
this.#commit();

0 commit comments

Comments
 (0)