Skip to content

Commit d5ba21f

Browse files
committed
collect all effects
1 parent 12ceae1 commit d5ba21f

File tree

1 file changed

+5
-5
lines changed
  • packages/svelte/src/internal/client/reactivity

1 file changed

+5
-5
lines changed

packages/svelte/src/internal/client/reactivity/batch.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -292,12 +292,12 @@ export class Batch {
292292
if (!skip && effect.fn !== null) {
293293
if (is_branch) {
294294
effect.f ^= CLEAN;
295+
} else if ((flags & EFFECT) !== 0) {
296+
this.#effects.push(effect);
297+
} else if (async_mode_flag && (flags & RENDER_EFFECT) !== 0) {
298+
this.#render_effects.push(effect);
295299
} else if ((flags & CLEAN) === 0) {
296-
if ((flags & EFFECT) !== 0) {
297-
this.#effects.push(effect);
298-
} else if (async_mode_flag && (flags & RENDER_EFFECT) !== 0) {
299-
this.#render_effects.push(effect);
300-
} else if ((flags & ASYNC) !== 0) {
300+
if ((flags & ASYNC) !== 0) {
301301
var effects = effect.b?.pending ? this.#boundary_async_effects : this.#async_effects;
302302
effects.push(effect);
303303
} else if (is_dirty(effect)) {

0 commit comments

Comments
 (0)