File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
packages/svelte/src/internal/client/reactivity Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -300,7 +300,8 @@ export function increment(source) {
300300}
301301
302302/**
303- * We increment this value when an effect is scheduled as a result of a state change
303+ * We increment this value when a block effect is scheduled as a result of a state change,
304+ * as its currently-scheduled child effects may need to be destroyed
304305 */
305306export let schedule_version = 0 ;
306307
@@ -339,7 +340,7 @@ function mark_reactions(signal, status) {
339340 if ( ( flags & DERIVED ) !== 0 ) {
340341 mark_reactions ( /** @type {Derived } */ ( reaction ) , MAYBE_DIRTY ) ;
341342 } else if ( not_dirty ) {
342- schedule_version += 1 ;
343+ if ( ( flags & BLOCK_EFFECT ) !== 0 ) schedule_version += 1 ;
343344 schedule_effect ( /** @type {Effect } */ ( reaction ) ) ;
344345 }
345346 }
You can’t perform that action at this time.
0 commit comments