vue 2.7.11 → 2.7.12

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.js v2.7.11
2
+ * Vue.js v2.7.12
3
3
  * (c) 2014-2022 Evan You
4
4
  * Released under the MIT License.
5
5
  */
@@ -3923,7 +3923,7 @@ function onErrorCaptured(hook, target = currentInstance) {
3923
3923
  /**
3924
3924
  * Note: also update dist/vue.runtime.mjs when adding new exports to this file.
3925
3925
  */
3926
- const version = '2.7.11';
3926
+ const version = '2.7.12';
3927
3927
  /**
3928
3928
  * @internal type is manually declared in <root>/types/v3-define-component.d.ts
3929
3929
  */
@@ -4191,6 +4191,10 @@ function proxy(target, sourceKey, key) {
4191
4191
  }
4192
4192
  function initState(vm) {
4193
4193
  const opts = vm.$options;
4194
+ if (opts.props)
4195
+ initProps$1(vm, opts.props);
4196
+ // Composition API
4197
+ initSetup(vm);
4194
4198
  if (opts.methods)
4195
4199
  initMethods(vm, opts.methods);
4196
4200
  if (opts.data) {
@@ -4207,8 +4211,6 @@ function initState(vm) {
4207
4211
  }
4208
4212
  }
4209
4213
  function initProps$1(vm, propsOptions) {
4210
- if (!propsOptions)
4211
- return;
4212
4214
  const propsData = vm.$options.propsData || {};
4213
4215
  const props = (vm._props = shallowReactive({}));
4214
4216
  // cache prop keys so that future props updates can iterate using Array
@@ -4569,11 +4571,8 @@ function initMixin$1(Vue) {
4569
4571
  initLifecycle(vm);
4570
4572
  initEvents(vm);
4571
4573
  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
4574
  callHook$1(vm, 'beforeCreate', undefined, false /* setContext */);
4575
+ initInjections(vm); // resolve injections before data/props
4577
4576
  initState(vm);
4578
4577
  initProvide(vm); // resolve provide after data/props
4579
4578
  callHook$1(vm, 'created');