vue 3.5.10 → 3.5.11

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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * vue v3.5.10
2
+ * vue v3.5.11
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -560,8 +560,14 @@ var Vue = (function (exports) {
560
560
  }
561
561
  let batchDepth = 0;
562
562
  let batchedSub;
563
- function batch(sub) {
563
+ let batchedComputed;
564
+ function batch(sub, isComputed = false) {
564
565
  sub.flags |= 8;
566
+ if (isComputed) {
567
+ sub.next = batchedComputed;
568
+ batchedComputed = sub;
569
+ return;
570
+ }
565
571
  sub.next = batchedSub;
566
572
  batchedSub = sub;
567
573
  }
@@ -572,20 +578,22 @@ var Vue = (function (exports) {
572
578
  if (--batchDepth > 0) {
573
579
  return;
574
580
  }
581
+ if (batchedComputed) {
582
+ let e = batchedComputed;
583
+ batchedComputed = void 0;
584
+ while (e) {
585
+ const next = e.next;
586
+ e.next = void 0;
587
+ e.flags &= ~8;
588
+ e = next;
589
+ }
590
+ }
575
591
  let error;
576
592
  while (batchedSub) {
577
593
  let e = batchedSub;
578
- let next;
579
- while (e) {
580
- if (!(e.flags & 1)) {
581
- e.flags &= ~8;
582
- }
583
- e = e.next;
584
- }
585
- e = batchedSub;
586
594
  batchedSub = void 0;
587
595
  while (e) {
588
- next = e.next;
596
+ const next = e.next;
589
597
  e.next = void 0;
590
598
  e.flags &= ~8;
591
599
  if (e.flags & 1) {
@@ -781,7 +789,6 @@ var Vue = (function (exports) {
781
789
  /**
782
790
  * For object property deps cleanup
783
791
  */
784
- this.target = void 0;
785
792
  this.map = void 0;
786
793
  this.key = void 0;
787
794
  /**
@@ -909,7 +916,6 @@ var Vue = (function (exports) {
909
916
  let dep = depsMap.get(key);
910
917
  if (!dep) {
911
918
  depsMap.set(key, dep = new Dep());
912
- dep.target = target;
913
919
  dep.map = depsMap;
914
920
  dep.key = key;
915
921
  }
@@ -1945,7 +1951,7 @@ var Vue = (function (exports) {
1945
1951
  this.flags |= 16;
1946
1952
  if (!(this.flags & 8) && // avoid infinite self recursion
1947
1953
  activeSub !== this) {
1948
- batch(this);
1954
+ batch(this, true);
1949
1955
  return true;
1950
1956
  }
1951
1957
  }
@@ -2467,10 +2473,8 @@ var Vue = (function (exports) {
2467
2473
  }
2468
2474
  }
2469
2475
 
2470
- let isFlushing = false;
2471
- let isFlushPending = false;
2472
2476
  const queue = [];
2473
- let flushIndex = 0;
2477
+ let flushIndex = -1;
2474
2478
  const pendingPostFlushCbs = [];
2475
2479
  let activePostFlushCbs = null;
2476
2480
  let postFlushIndex = 0;
@@ -2482,7 +2486,7 @@ var Vue = (function (exports) {
2482
2486
  return fn ? p.then(this ? fn.bind(this) : fn) : p;
2483
2487
  }
2484
2488
  function findInsertionIndex(id) {
2485
- let start = isFlushing ? flushIndex + 1 : 0;
2489
+ let start = flushIndex + 1;
2486
2490
  let end = queue.length;
2487
2491
  while (start < end) {
2488
2492
  const middle = start + end >>> 1;
@@ -2511,8 +2515,7 @@ var Vue = (function (exports) {
2511
2515
  }
2512
2516
  }
2513
2517
  function queueFlush() {
2514
- if (!isFlushing && !isFlushPending) {
2515
- isFlushPending = true;
2518
+ if (!currentFlushPromise) {
2516
2519
  currentFlushPromise = resolvedPromise.then(flushJobs);
2517
2520
  }
2518
2521
  }
@@ -2529,7 +2532,7 @@ var Vue = (function (exports) {
2529
2532
  }
2530
2533
  queueFlush();
2531
2534
  }
2532
- function flushPreFlushCbs(instance, seen, i = isFlushing ? flushIndex + 1 : 0) {
2535
+ function flushPreFlushCbs(instance, seen, i = flushIndex + 1) {
2533
2536
  {
2534
2537
  seen = seen || /* @__PURE__ */ new Map();
2535
2538
  }
@@ -2585,8 +2588,6 @@ var Vue = (function (exports) {
2585
2588
  }
2586
2589
  const getId = (job) => job.id == null ? job.flags & 2 ? -1 : Infinity : job.id;
2587
2590
  function flushJobs(seen) {
2588
- isFlushPending = false;
2589
- isFlushing = true;
2590
2591
  {
2591
2592
  seen = seen || /* @__PURE__ */ new Map();
2592
2593
  }
@@ -2618,10 +2619,9 @@ var Vue = (function (exports) {
2618
2619
  job.flags &= ~1;
2619
2620
  }
2620
2621
  }
2621
- flushIndex = 0;
2622
+ flushIndex = -1;
2622
2623
  queue.length = 0;
2623
2624
  flushPostFlushCbs(seen);
2624
- isFlushing = false;
2625
2625
  currentFlushPromise = null;
2626
2626
  if (queue.length || pendingPostFlushCbs.length) {
2627
2627
  flushJobs(seen);
@@ -10409,7 +10409,7 @@ Component that was made reactive: `,
10409
10409
  return true;
10410
10410
  }
10411
10411
 
10412
- const version = "3.5.10";
10412
+ const version = "3.5.11";
10413
10413
  const warn = warn$1 ;
10414
10414
  const ErrorTypeStrings = ErrorTypeStrings$1 ;
10415
10415
  const devtools = devtools$1 ;