@solidjs/signals 2.0.0-beta.29 → 2.0.0-beta.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/dev.js +22 -1
- package/dist/node.cjs +430 -413
- package/dist/prod/core/heap.js +1 -1
- package/dist/prod/core/scheduler.js +39 -22
- package/dist/prod/core/verdict.js +1 -1
- package/dist/prod/map.js +56 -56
- package/dist/prod/store/store.js +2 -2
- package/package.json +1 -1
package/dist/dev.js
CHANGED
|
@@ -429,6 +429,16 @@ const zombieQueue = {
|
|
|
429
429
|
_min: 0,
|
|
430
430
|
_max: 0
|
|
431
431
|
};
|
|
432
|
+
/** runHeap callback that discards a queued zombie recompute instead of running
|
|
433
|
+
* it: unlink pure recompute entries; strip just the recompute bit from dirtied
|
|
434
|
+
* height-adjust entries so their height work still happens. */
|
|
435
|
+
function cancelZombieRecompute(el) {
|
|
436
|
+
if (el._flags & REACTIVE_IN_HEAP_HEIGHT) el._flags &= -12;
|
|
437
|
+
else {
|
|
438
|
+
deleteFromHeap(el, zombieQueue);
|
|
439
|
+
el._flags &= -4;
|
|
440
|
+
}
|
|
441
|
+
}
|
|
432
442
|
let clock = 0;
|
|
433
443
|
let activeTransition = null;
|
|
434
444
|
let scheduled = false;
|
|
@@ -748,7 +758,18 @@ class GlobalQueue extends Queue {
|
|
|
748
758
|
const isComplete = transitionComplete(activeTransition);
|
|
749
759
|
if (!isComplete) {
|
|
750
760
|
const stashedTransition = activeTransition;
|
|
751
|
-
|
|
761
|
+
// When the parking batch IS the transition, all of its writes commit
|
|
762
|
+
// only with it — every zombie recompute they queued would run against
|
|
763
|
+
// a world the zombie never displays (zombies render mainline until
|
|
764
|
+
// commit), so cancel them instead of running them. Only an ambient
|
|
765
|
+
// batch's mainline writes (the #2916 shape below) legitimately reach
|
|
766
|
+
// zombies here. Height-adjust entries still process normally: a
|
|
767
|
+
// dirtied one keeps its height flag and falls through to runHeap's
|
|
768
|
+
// adjustHeight path on the next pass of the bucket.
|
|
769
|
+
runHeap(
|
|
770
|
+
zombieQueue,
|
|
771
|
+
this._batch === stashedTransition ? cancelZombieRecompute : GlobalQueue._update
|
|
772
|
+
);
|
|
752
773
|
// Detach: the stashed transition keeps its batch; ambient work that
|
|
753
774
|
// follows lands in a fresh one. If the batch is already a separate
|
|
754
775
|
// ambient one — action done() restored activeTransition without
|