@vue/compat 3.5.3 → 3.5.4
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/vue.cjs.js +53 -64
- package/dist/vue.cjs.prod.js +34 -37
- package/dist/vue.esm-browser.js +53 -64
- package/dist/vue.esm-browser.prod.js +4 -4
- package/dist/vue.esm-bundler.js +55 -66
- package/dist/vue.global.js +53 -64
- package/dist/vue.global.prod.js +2 -2
- package/dist/vue.runtime.esm-browser.js +50 -54
- package/dist/vue.runtime.esm-browser.prod.js +2 -2
- package/dist/vue.runtime.esm-bundler.js +52 -56
- package/dist/vue.runtime.global.js +50 -54
- package/dist/vue.runtime.global.prod.js +2 -2
- package/package.json +2 -2
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.4
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
6
6
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
7
7
|
// @__NO_SIDE_EFFECTS__
|
|
8
|
-
function makeMap(str
|
|
9
|
-
const
|
|
10
|
-
|
|
8
|
+
function makeMap(str) {
|
|
9
|
+
const map = /* @__PURE__ */ Object.create(null);
|
|
10
|
+
for (const key of str.split(",")) map[key] = 1;
|
|
11
|
+
return (val) => val in map;
|
|
11
12
|
}
|
|
12
13
|
|
|
13
14
|
const EMPTY_OBJ = !!(process.env.NODE_ENV !== "production") ? Object.freeze({}) : {};
|
|
@@ -611,7 +612,7 @@ function cleanupDeps(sub) {
|
|
|
611
612
|
}
|
|
612
613
|
function isDirty(sub) {
|
|
613
614
|
for (let link = sub.deps; link; link = link.nextDep) {
|
|
614
|
-
if (link.dep.version !== link.version || link.dep.computed && refreshComputed(link.dep.computed)
|
|
615
|
+
if (link.dep.version !== link.version || link.dep.computed && refreshComputed(link.dep.computed) || link.dep.version !== link.version) {
|
|
615
616
|
return true;
|
|
616
617
|
}
|
|
617
618
|
}
|
|
@@ -621,9 +622,6 @@ function isDirty(sub) {
|
|
|
621
622
|
return false;
|
|
622
623
|
}
|
|
623
624
|
function refreshComputed(computed) {
|
|
624
|
-
if (computed.flags & 2) {
|
|
625
|
-
return false;
|
|
626
|
-
}
|
|
627
625
|
if (computed.flags & 4 && !(computed.flags & 16)) {
|
|
628
626
|
return;
|
|
629
627
|
}
|
|
@@ -892,9 +890,25 @@ function trigger(target, type, key, newValue, oldValue, oldTarget) {
|
|
|
892
890
|
globalVersion++;
|
|
893
891
|
return;
|
|
894
892
|
}
|
|
895
|
-
|
|
893
|
+
const run = (dep) => {
|
|
894
|
+
if (dep) {
|
|
895
|
+
if (!!(process.env.NODE_ENV !== "production")) {
|
|
896
|
+
dep.trigger({
|
|
897
|
+
target,
|
|
898
|
+
type,
|
|
899
|
+
key,
|
|
900
|
+
newValue,
|
|
901
|
+
oldValue,
|
|
902
|
+
oldTarget
|
|
903
|
+
});
|
|
904
|
+
} else {
|
|
905
|
+
dep.trigger();
|
|
906
|
+
}
|
|
907
|
+
}
|
|
908
|
+
};
|
|
909
|
+
startBatch();
|
|
896
910
|
if (type === "clear") {
|
|
897
|
-
|
|
911
|
+
depsMap.forEach(run);
|
|
898
912
|
} else {
|
|
899
913
|
const targetIsArray = isArray(target);
|
|
900
914
|
const isArrayIndex = targetIsArray && isIntegerKey(key);
|
|
@@ -902,59 +916,43 @@ function trigger(target, type, key, newValue, oldValue, oldTarget) {
|
|
|
902
916
|
const newLength = Number(newValue);
|
|
903
917
|
depsMap.forEach((dep, key2) => {
|
|
904
918
|
if (key2 === "length" || key2 === ARRAY_ITERATE_KEY || !isSymbol(key2) && key2 >= newLength) {
|
|
905
|
-
|
|
919
|
+
run(dep);
|
|
906
920
|
}
|
|
907
921
|
});
|
|
908
922
|
} else {
|
|
909
|
-
const push = (dep) => dep && deps.push(dep);
|
|
910
923
|
if (key !== void 0) {
|
|
911
|
-
|
|
924
|
+
run(depsMap.get(key));
|
|
912
925
|
}
|
|
913
926
|
if (isArrayIndex) {
|
|
914
|
-
|
|
927
|
+
run(depsMap.get(ARRAY_ITERATE_KEY));
|
|
915
928
|
}
|
|
916
929
|
switch (type) {
|
|
917
930
|
case "add":
|
|
918
931
|
if (!targetIsArray) {
|
|
919
|
-
|
|
932
|
+
run(depsMap.get(ITERATE_KEY));
|
|
920
933
|
if (isMap(target)) {
|
|
921
|
-
|
|
934
|
+
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
922
935
|
}
|
|
923
936
|
} else if (isArrayIndex) {
|
|
924
|
-
|
|
937
|
+
run(depsMap.get("length"));
|
|
925
938
|
}
|
|
926
939
|
break;
|
|
927
940
|
case "delete":
|
|
928
941
|
if (!targetIsArray) {
|
|
929
|
-
|
|
942
|
+
run(depsMap.get(ITERATE_KEY));
|
|
930
943
|
if (isMap(target)) {
|
|
931
|
-
|
|
944
|
+
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
932
945
|
}
|
|
933
946
|
}
|
|
934
947
|
break;
|
|
935
948
|
case "set":
|
|
936
949
|
if (isMap(target)) {
|
|
937
|
-
|
|
950
|
+
run(depsMap.get(ITERATE_KEY));
|
|
938
951
|
}
|
|
939
952
|
break;
|
|
940
953
|
}
|
|
941
954
|
}
|
|
942
955
|
}
|
|
943
|
-
startBatch();
|
|
944
|
-
for (const dep of deps) {
|
|
945
|
-
if (!!(process.env.NODE_ENV !== "production")) {
|
|
946
|
-
dep.trigger({
|
|
947
|
-
target,
|
|
948
|
-
type,
|
|
949
|
-
key,
|
|
950
|
-
newValue,
|
|
951
|
-
oldValue,
|
|
952
|
-
oldTarget
|
|
953
|
-
});
|
|
954
|
-
} else {
|
|
955
|
-
dep.trigger();
|
|
956
|
-
}
|
|
957
|
-
}
|
|
958
956
|
endBatch();
|
|
959
957
|
}
|
|
960
958
|
function getDepFromReactive(object, key) {
|
|
@@ -1692,7 +1690,7 @@ function toRaw(observed) {
|
|
|
1692
1690
|
return raw ? toRaw(raw) : observed;
|
|
1693
1691
|
}
|
|
1694
1692
|
function markRaw(value) {
|
|
1695
|
-
if (Object.isExtensible(value)) {
|
|
1693
|
+
if (!hasOwn(value, "__v_skip") && Object.isExtensible(value)) {
|
|
1696
1694
|
def(value, "__v_skip", true);
|
|
1697
1695
|
}
|
|
1698
1696
|
return value;
|
|
@@ -1908,8 +1906,8 @@ class ComputedRefImpl {
|
|
|
1908
1906
|
* @internal
|
|
1909
1907
|
*/
|
|
1910
1908
|
notify() {
|
|
1909
|
+
this.flags |= 16;
|
|
1911
1910
|
if (activeSub !== this) {
|
|
1912
|
-
this.flags |= 16;
|
|
1913
1911
|
this.dep.notify();
|
|
1914
1912
|
} else if (!!(process.env.NODE_ENV !== "production")) ;
|
|
1915
1913
|
}
|
|
@@ -2602,23 +2600,19 @@ function flushJobs(seen) {
|
|
|
2602
2600
|
}
|
|
2603
2601
|
}
|
|
2604
2602
|
function checkRecursiveUpdates(seen, fn) {
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
const
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2612
|
-
|
|
2613
|
-
|
|
2614
|
-
|
|
2615
|
-
10
|
|
2616
|
-
);
|
|
2617
|
-
return true;
|
|
2618
|
-
} else {
|
|
2619
|
-
seen.set(fn, count + 1);
|
|
2620
|
-
}
|
|
2603
|
+
const count = seen.get(fn) || 0;
|
|
2604
|
+
if (count > RECURSION_LIMIT) {
|
|
2605
|
+
const instance = fn.i;
|
|
2606
|
+
const componentName = instance && getComponentName(instance.type);
|
|
2607
|
+
handleError(
|
|
2608
|
+
`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`,
|
|
2609
|
+
null,
|
|
2610
|
+
10
|
|
2611
|
+
);
|
|
2612
|
+
return true;
|
|
2621
2613
|
}
|
|
2614
|
+
seen.set(fn, count + 1);
|
|
2615
|
+
return false;
|
|
2622
2616
|
}
|
|
2623
2617
|
|
|
2624
2618
|
let isHmrUpdating = false;
|
|
@@ -5809,13 +5803,15 @@ function renderList(source, renderItem, cache, index) {
|
|
|
5809
5803
|
const sourceIsArray = isArray(source);
|
|
5810
5804
|
if (sourceIsArray || isString(source)) {
|
|
5811
5805
|
const sourceIsReactiveArray = sourceIsArray && isReactive(source);
|
|
5806
|
+
let needsWrap = false;
|
|
5812
5807
|
if (sourceIsReactiveArray) {
|
|
5808
|
+
needsWrap = !isShallow(source);
|
|
5813
5809
|
source = shallowReadArray(source);
|
|
5814
5810
|
}
|
|
5815
5811
|
ret = new Array(source.length);
|
|
5816
5812
|
for (let i = 0, l = source.length; i < l; i++) {
|
|
5817
5813
|
ret[i] = renderItem(
|
|
5818
|
-
|
|
5814
|
+
needsWrap ? toReactive(source[i]) : source[i],
|
|
5819
5815
|
i,
|
|
5820
5816
|
void 0,
|
|
5821
5817
|
cached && cached[i]
|
|
@@ -7068,7 +7064,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7068
7064
|
return vm;
|
|
7069
7065
|
}
|
|
7070
7066
|
}
|
|
7071
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7067
|
+
Vue.version = `2.6.14-compat:${"3.5.4"}`;
|
|
7072
7068
|
Vue.config = singletonApp.config;
|
|
7073
7069
|
Vue.use = (plugin, ...options) => {
|
|
7074
7070
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -12235,7 +12231,7 @@ function isMemoSame(cached, memo) {
|
|
|
12235
12231
|
return true;
|
|
12236
12232
|
}
|
|
12237
12233
|
|
|
12238
|
-
const version = "3.5.
|
|
12234
|
+
const version = "3.5.4";
|
|
12239
12235
|
const warn = !!(process.env.NODE_ENV !== "production") ? warn$1 : NOOP;
|
|
12240
12236
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12241
12237
|
const devtools = !!(process.env.NODE_ENV !== "production") || true ? devtools$1 : void 0;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.4
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -8,9 +8,10 @@ var Vue = (function () {
|
|
|
8
8
|
|
|
9
9
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
10
10
|
// @__NO_SIDE_EFFECTS__
|
|
11
|
-
function makeMap(str
|
|
12
|
-
const
|
|
13
|
-
|
|
11
|
+
function makeMap(str) {
|
|
12
|
+
const map = /* @__PURE__ */ Object.create(null);
|
|
13
|
+
for (const key of str.split(",")) map[key] = 1;
|
|
14
|
+
return (val) => val in map;
|
|
14
15
|
}
|
|
15
16
|
|
|
16
17
|
const EMPTY_OBJ = Object.freeze({}) ;
|
|
@@ -614,7 +615,7 @@ var Vue = (function () {
|
|
|
614
615
|
}
|
|
615
616
|
function isDirty(sub) {
|
|
616
617
|
for (let link = sub.deps; link; link = link.nextDep) {
|
|
617
|
-
if (link.dep.version !== link.version || link.dep.computed && refreshComputed(link.dep.computed)
|
|
618
|
+
if (link.dep.version !== link.version || link.dep.computed && refreshComputed(link.dep.computed) || link.dep.version !== link.version) {
|
|
618
619
|
return true;
|
|
619
620
|
}
|
|
620
621
|
}
|
|
@@ -624,9 +625,6 @@ var Vue = (function () {
|
|
|
624
625
|
return false;
|
|
625
626
|
}
|
|
626
627
|
function refreshComputed(computed) {
|
|
627
|
-
if (computed.flags & 2) {
|
|
628
|
-
return false;
|
|
629
|
-
}
|
|
630
628
|
if (computed.flags & 4 && !(computed.flags & 16)) {
|
|
631
629
|
return;
|
|
632
630
|
}
|
|
@@ -893,9 +891,23 @@ var Vue = (function () {
|
|
|
893
891
|
globalVersion++;
|
|
894
892
|
return;
|
|
895
893
|
}
|
|
896
|
-
|
|
894
|
+
const run = (dep) => {
|
|
895
|
+
if (dep) {
|
|
896
|
+
{
|
|
897
|
+
dep.trigger({
|
|
898
|
+
target,
|
|
899
|
+
type,
|
|
900
|
+
key,
|
|
901
|
+
newValue,
|
|
902
|
+
oldValue,
|
|
903
|
+
oldTarget
|
|
904
|
+
});
|
|
905
|
+
}
|
|
906
|
+
}
|
|
907
|
+
};
|
|
908
|
+
startBatch();
|
|
897
909
|
if (type === "clear") {
|
|
898
|
-
|
|
910
|
+
depsMap.forEach(run);
|
|
899
911
|
} else {
|
|
900
912
|
const targetIsArray = isArray(target);
|
|
901
913
|
const isArrayIndex = targetIsArray && isIntegerKey(key);
|
|
@@ -903,57 +915,43 @@ var Vue = (function () {
|
|
|
903
915
|
const newLength = Number(newValue);
|
|
904
916
|
depsMap.forEach((dep, key2) => {
|
|
905
917
|
if (key2 === "length" || key2 === ARRAY_ITERATE_KEY || !isSymbol(key2) && key2 >= newLength) {
|
|
906
|
-
|
|
918
|
+
run(dep);
|
|
907
919
|
}
|
|
908
920
|
});
|
|
909
921
|
} else {
|
|
910
|
-
const push = (dep) => dep && deps.push(dep);
|
|
911
922
|
if (key !== void 0) {
|
|
912
|
-
|
|
923
|
+
run(depsMap.get(key));
|
|
913
924
|
}
|
|
914
925
|
if (isArrayIndex) {
|
|
915
|
-
|
|
926
|
+
run(depsMap.get(ARRAY_ITERATE_KEY));
|
|
916
927
|
}
|
|
917
928
|
switch (type) {
|
|
918
929
|
case "add":
|
|
919
930
|
if (!targetIsArray) {
|
|
920
|
-
|
|
931
|
+
run(depsMap.get(ITERATE_KEY));
|
|
921
932
|
if (isMap(target)) {
|
|
922
|
-
|
|
933
|
+
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
923
934
|
}
|
|
924
935
|
} else if (isArrayIndex) {
|
|
925
|
-
|
|
936
|
+
run(depsMap.get("length"));
|
|
926
937
|
}
|
|
927
938
|
break;
|
|
928
939
|
case "delete":
|
|
929
940
|
if (!targetIsArray) {
|
|
930
|
-
|
|
941
|
+
run(depsMap.get(ITERATE_KEY));
|
|
931
942
|
if (isMap(target)) {
|
|
932
|
-
|
|
943
|
+
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
933
944
|
}
|
|
934
945
|
}
|
|
935
946
|
break;
|
|
936
947
|
case "set":
|
|
937
948
|
if (isMap(target)) {
|
|
938
|
-
|
|
949
|
+
run(depsMap.get(ITERATE_KEY));
|
|
939
950
|
}
|
|
940
951
|
break;
|
|
941
952
|
}
|
|
942
953
|
}
|
|
943
954
|
}
|
|
944
|
-
startBatch();
|
|
945
|
-
for (const dep of deps) {
|
|
946
|
-
{
|
|
947
|
-
dep.trigger({
|
|
948
|
-
target,
|
|
949
|
-
type,
|
|
950
|
-
key,
|
|
951
|
-
newValue,
|
|
952
|
-
oldValue,
|
|
953
|
-
oldTarget
|
|
954
|
-
});
|
|
955
|
-
}
|
|
956
|
-
}
|
|
957
955
|
endBatch();
|
|
958
956
|
}
|
|
959
957
|
function getDepFromReactive(object, key) {
|
|
@@ -1691,7 +1689,7 @@ var Vue = (function () {
|
|
|
1691
1689
|
return raw ? toRaw(raw) : observed;
|
|
1692
1690
|
}
|
|
1693
1691
|
function markRaw(value) {
|
|
1694
|
-
if (Object.isExtensible(value)) {
|
|
1692
|
+
if (!hasOwn(value, "__v_skip") && Object.isExtensible(value)) {
|
|
1695
1693
|
def(value, "__v_skip", true);
|
|
1696
1694
|
}
|
|
1697
1695
|
return value;
|
|
@@ -1901,8 +1899,8 @@ var Vue = (function () {
|
|
|
1901
1899
|
* @internal
|
|
1902
1900
|
*/
|
|
1903
1901
|
notify() {
|
|
1902
|
+
this.flags |= 16;
|
|
1904
1903
|
if (activeSub !== this) {
|
|
1905
|
-
this.flags |= 16;
|
|
1906
1904
|
this.dep.notify();
|
|
1907
1905
|
}
|
|
1908
1906
|
}
|
|
@@ -2590,23 +2588,19 @@ var Vue = (function () {
|
|
|
2590
2588
|
}
|
|
2591
2589
|
}
|
|
2592
2590
|
function checkRecursiveUpdates(seen, fn) {
|
|
2593
|
-
|
|
2594
|
-
|
|
2595
|
-
|
|
2596
|
-
const
|
|
2597
|
-
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
|
-
|
|
2601
|
-
|
|
2602
|
-
|
|
2603
|
-
10
|
|
2604
|
-
);
|
|
2605
|
-
return true;
|
|
2606
|
-
} else {
|
|
2607
|
-
seen.set(fn, count + 1);
|
|
2608
|
-
}
|
|
2591
|
+
const count = seen.get(fn) || 0;
|
|
2592
|
+
if (count > RECURSION_LIMIT) {
|
|
2593
|
+
const instance = fn.i;
|
|
2594
|
+
const componentName = instance && getComponentName(instance.type);
|
|
2595
|
+
handleError(
|
|
2596
|
+
`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`,
|
|
2597
|
+
null,
|
|
2598
|
+
10
|
|
2599
|
+
);
|
|
2600
|
+
return true;
|
|
2609
2601
|
}
|
|
2602
|
+
seen.set(fn, count + 1);
|
|
2603
|
+
return false;
|
|
2610
2604
|
}
|
|
2611
2605
|
|
|
2612
2606
|
let isHmrUpdating = false;
|
|
@@ -5776,13 +5770,15 @@ If this is a native custom element, make sure to exclude it from component resol
|
|
|
5776
5770
|
const sourceIsArray = isArray(source);
|
|
5777
5771
|
if (sourceIsArray || isString(source)) {
|
|
5778
5772
|
const sourceIsReactiveArray = sourceIsArray && isReactive(source);
|
|
5773
|
+
let needsWrap = false;
|
|
5779
5774
|
if (sourceIsReactiveArray) {
|
|
5775
|
+
needsWrap = !isShallow(source);
|
|
5780
5776
|
source = shallowReadArray(source);
|
|
5781
5777
|
}
|
|
5782
5778
|
ret = new Array(source.length);
|
|
5783
5779
|
for (let i = 0, l = source.length; i < l; i++) {
|
|
5784
5780
|
ret[i] = renderItem(
|
|
5785
|
-
|
|
5781
|
+
needsWrap ? toReactive(source[i]) : source[i],
|
|
5786
5782
|
i,
|
|
5787
5783
|
void 0,
|
|
5788
5784
|
cached && cached[i]
|
|
@@ -7030,7 +7026,7 @@ If this is a native custom element, make sure to exclude it from component resol
|
|
|
7030
7026
|
return vm;
|
|
7031
7027
|
}
|
|
7032
7028
|
}
|
|
7033
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7029
|
+
Vue.version = `2.6.14-compat:${"3.5.4"}`;
|
|
7034
7030
|
Vue.config = singletonApp.config;
|
|
7035
7031
|
Vue.use = (plugin, ...options) => {
|
|
7036
7032
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -12107,7 +12103,7 @@ Component that was made reactive: `,
|
|
|
12107
12103
|
return true;
|
|
12108
12104
|
}
|
|
12109
12105
|
|
|
12110
|
-
const version = "3.5.
|
|
12106
|
+
const version = "3.5.4";
|
|
12111
12107
|
const warn = warn$1 ;
|
|
12112
12108
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12113
12109
|
const devtools = devtools$1 ;
|