vue 2.7.11 → 2.7.13
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.common.dev.js +12 -10
- package/dist/vue.common.prod.js +3 -3
- package/dist/vue.esm.browser.js +12 -10
- package/dist/vue.esm.browser.min.js +3 -3
- package/dist/vue.esm.js +12 -10
- package/dist/vue.js +12 -10
- package/dist/vue.min.js +3 -3
- package/dist/vue.runtime.common.dev.js +12 -10
- package/dist/vue.runtime.common.prod.js +3 -3
- package/dist/vue.runtime.esm.js +12 -10
- package/dist/vue.runtime.js +12 -10
- package/dist/vue.runtime.min.js +3 -3
- package/package.json +2 -2
- package/packages/compiler-sfc/dist/compiler-sfc.js +1 -0
- package/packages/compiler-sfc/package.json +1 -1
- package/src/core/instance/init.ts +2 -7
- package/src/core/instance/state.ts +7 -2
- package/src/core/observer/traverse.ts +1 -0
- package/src/v3/reactivity/effectScope.ts +4 -5
- package/types/jsx.d.ts +1 -1
- package/types/v3-generated.d.ts +1 -0
package/dist/vue.esm.browser.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Vue.js v2.7.
|
|
2
|
+
* Vue.js v2.7.13
|
|
3
3
|
* (c) 2014-2022 Evan You
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -3432,6 +3432,7 @@ function doWatch(source, cb, { immediate, deep, flush = 'pre', onTrack, onTrigge
|
|
|
3432
3432
|
let activeEffectScope;
|
|
3433
3433
|
class EffectScope {
|
|
3434
3434
|
constructor(detached = false) {
|
|
3435
|
+
this.detached = detached;
|
|
3435
3436
|
/**
|
|
3436
3437
|
* @internal
|
|
3437
3438
|
*/
|
|
@@ -3444,8 +3445,8 @@ class EffectScope {
|
|
|
3444
3445
|
* @internal
|
|
3445
3446
|
*/
|
|
3446
3447
|
this.cleanups = [];
|
|
3448
|
+
this.parent = activeEffectScope;
|
|
3447
3449
|
if (!detached && activeEffectScope) {
|
|
3448
|
-
this.parent = activeEffectScope;
|
|
3449
3450
|
this.index =
|
|
3450
3451
|
(activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(this) - 1;
|
|
3451
3452
|
}
|
|
@@ -3494,7 +3495,7 @@ class EffectScope {
|
|
|
3494
3495
|
}
|
|
3495
3496
|
}
|
|
3496
3497
|
// nested scope, dereference from parent to avoid memory leaks
|
|
3497
|
-
if (this.parent && !fromParent) {
|
|
3498
|
+
if (!this.detached && this.parent && !fromParent) {
|
|
3498
3499
|
// optimized O(1) removal
|
|
3499
3500
|
const last = this.parent.scopes.pop();
|
|
3500
3501
|
if (last && last !== this) {
|
|
@@ -3502,6 +3503,7 @@ class EffectScope {
|
|
|
3502
3503
|
last.index = this.index;
|
|
3503
3504
|
}
|
|
3504
3505
|
}
|
|
3506
|
+
this.parent = undefined;
|
|
3505
3507
|
this.active = false;
|
|
3506
3508
|
}
|
|
3507
3509
|
}
|
|
@@ -3923,7 +3925,7 @@ function onErrorCaptured(hook, target = currentInstance) {
|
|
|
3923
3925
|
/**
|
|
3924
3926
|
* Note: also update dist/vue.runtime.mjs when adding new exports to this file.
|
|
3925
3927
|
*/
|
|
3926
|
-
const version = '2.7.
|
|
3928
|
+
const version = '2.7.13';
|
|
3927
3929
|
/**
|
|
3928
3930
|
* @internal type is manually declared in <root>/types/v3-define-component.d.ts
|
|
3929
3931
|
*/
|
|
@@ -3946,6 +3948,7 @@ function _traverse(val, seen) {
|
|
|
3946
3948
|
let i, keys;
|
|
3947
3949
|
const isA = isArray(val);
|
|
3948
3950
|
if ((!isA && !isObject(val)) ||
|
|
3951
|
+
val.__v_skip /* ReactiveFlags.SKIP */ ||
|
|
3949
3952
|
Object.isFrozen(val) ||
|
|
3950
3953
|
val instanceof VNode) {
|
|
3951
3954
|
return;
|
|
@@ -4191,6 +4194,10 @@ function proxy(target, sourceKey, key) {
|
|
|
4191
4194
|
}
|
|
4192
4195
|
function initState(vm) {
|
|
4193
4196
|
const opts = vm.$options;
|
|
4197
|
+
if (opts.props)
|
|
4198
|
+
initProps$1(vm, opts.props);
|
|
4199
|
+
// Composition API
|
|
4200
|
+
initSetup(vm);
|
|
4194
4201
|
if (opts.methods)
|
|
4195
4202
|
initMethods(vm, opts.methods);
|
|
4196
4203
|
if (opts.data) {
|
|
@@ -4207,8 +4214,6 @@ function initState(vm) {
|
|
|
4207
4214
|
}
|
|
4208
4215
|
}
|
|
4209
4216
|
function initProps$1(vm, propsOptions) {
|
|
4210
|
-
if (!propsOptions)
|
|
4211
|
-
return;
|
|
4212
4217
|
const propsData = vm.$options.propsData || {};
|
|
4213
4218
|
const props = (vm._props = shallowReactive({}));
|
|
4214
4219
|
// cache prop keys so that future props updates can iterate using Array
|
|
@@ -4569,11 +4574,8 @@ function initMixin$1(Vue) {
|
|
|
4569
4574
|
initLifecycle(vm);
|
|
4570
4575
|
initEvents(vm);
|
|
4571
4576
|
initRender(vm);
|
|
4572
|
-
const opts = vm.$options;
|
|
4573
|
-
initInjections(vm); // resolve injections before data/props
|
|
4574
|
-
initProps$1(vm, opts.props);
|
|
4575
|
-
initSetup(vm);
|
|
4576
4577
|
callHook$1(vm, 'beforeCreate', undefined, false /* setContext */);
|
|
4578
|
+
initInjections(vm); // resolve injections before data/props
|
|
4577
4579
|
initState(vm);
|
|
4578
4580
|
initProvide(vm); // resolve provide after data/props
|
|
4579
4581
|
callHook$1(vm, 'created');
|