@vue/compat 3.2.30 → 3.2.31

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.
@@ -6089,7 +6089,7 @@ function createCompatVue(createApp, createSingletonApp) {
6089
6089
  return vm;
6090
6090
  }
6091
6091
  }
6092
- Vue.version = `2.6.14-compat:${"3.2.30"}`;
6092
+ Vue.version = `2.6.14-compat:${"3.2.31"}`;
6093
6093
  Vue.config = singletonApp.config;
6094
6094
  Vue.use = (p, ...options) => {
6095
6095
  if (p && isFunction(p.install)) {
@@ -6920,7 +6920,8 @@ function createHydrationFunctions(rendererInternals) {
6920
6920
  // e.g. <option :value="obj">, <input type="checkbox" :true-value="1">
6921
6921
  const forcePatchValue = (type === 'input' && dirs) || type === 'option';
6922
6922
  // skip props & children if this is hoisted static nodes
6923
- if (forcePatchValue || patchFlag !== -1 /* HOISTED */) {
6923
+ // #5405 in dev, always hydrate children for HMR
6924
+ if ((process.env.NODE_ENV !== 'production') || forcePatchValue || patchFlag !== -1 /* HOISTED */) {
6924
6925
  if (dirs) {
6925
6926
  invokeDirectiveHook(vnode, null, parentComponent, 'created');
6926
6927
  }
@@ -10125,9 +10126,11 @@ const PublicInstanceProxyHandlers = {
10125
10126
  const { data, setupState, ctx } = instance;
10126
10127
  if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {
10127
10128
  setupState[key] = value;
10129
+ return true;
10128
10130
  }
10129
10131
  else if (data !== EMPTY_OBJ && hasOwn(data, key)) {
10130
10132
  data[key] = value;
10133
+ return true;
10131
10134
  }
10132
10135
  else if (hasOwn(instance.props, key)) {
10133
10136
  (process.env.NODE_ENV !== 'production') &&
@@ -10163,6 +10166,15 @@ const PublicInstanceProxyHandlers = {
10163
10166
  hasOwn(ctx, key) ||
10164
10167
  hasOwn(publicPropertiesMap, key) ||
10165
10168
  hasOwn(appContext.config.globalProperties, key));
10169
+ },
10170
+ defineProperty(target, key, descriptor) {
10171
+ if (descriptor.get != null) {
10172
+ this.set(target, key, descriptor.get(), null);
10173
+ }
10174
+ else if (descriptor.value != null) {
10175
+ this.set(target, key, descriptor.value, null);
10176
+ }
10177
+ return Reflect.defineProperty(target, key, descriptor);
10166
10178
  }
10167
10179
  };
10168
10180
  if ((process.env.NODE_ENV !== 'production') && !false) {
@@ -11077,7 +11089,7 @@ function isMemoSame(cached, memo) {
11077
11089
  }
11078
11090
 
11079
11091
  // Core API ------------------------------------------------------------------
11080
- const version = "3.2.30";
11092
+ const version = "3.2.31";
11081
11093
  const _ssrUtils = {
11082
11094
  createComponentInstance,
11083
11095
  setupComponent,
@@ -6035,7 +6035,7 @@ var Vue = (function () {
6035
6035
  return vm;
6036
6036
  }
6037
6037
  }
6038
- Vue.version = `2.6.14-compat:${"3.2.30"}`;
6038
+ Vue.version = `2.6.14-compat:${"3.2.31"}`;
6039
6039
  Vue.config = singletonApp.config;
6040
6040
  Vue.use = (p, ...options) => {
6041
6041
  if (p && isFunction(p.install)) {
@@ -6859,7 +6859,8 @@ var Vue = (function () {
6859
6859
  // e.g. <option :value="obj">, <input type="checkbox" :true-value="1">
6860
6860
  const forcePatchValue = (type === 'input' && dirs) || type === 'option';
6861
6861
  // skip props & children if this is hoisted static nodes
6862
- if (forcePatchValue || patchFlag !== -1 /* HOISTED */) {
6862
+ // #5405 in dev, always hydrate children for HMR
6863
+ {
6863
6864
  if (dirs) {
6864
6865
  invokeDirectiveHook(vnode, null, parentComponent, 'created');
6865
6866
  }
@@ -10013,9 +10014,11 @@ var Vue = (function () {
10013
10014
  const { data, setupState, ctx } = instance;
10014
10015
  if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {
10015
10016
  setupState[key] = value;
10017
+ return true;
10016
10018
  }
10017
10019
  else if (data !== EMPTY_OBJ && hasOwn(data, key)) {
10018
10020
  data[key] = value;
10021
+ return true;
10019
10022
  }
10020
10023
  else if (hasOwn(instance.props, key)) {
10021
10024
  warn$1(`Attempting to mutate prop "${key}". Props are readonly.`, instance);
@@ -10049,6 +10052,15 @@ var Vue = (function () {
10049
10052
  hasOwn(ctx, key) ||
10050
10053
  hasOwn(publicPropertiesMap, key) ||
10051
10054
  hasOwn(appContext.config.globalProperties, key));
10055
+ },
10056
+ defineProperty(target, key, descriptor) {
10057
+ if (descriptor.get != null) {
10058
+ this.set(target, key, descriptor.get(), null);
10059
+ }
10060
+ else if (descriptor.value != null) {
10061
+ this.set(target, key, descriptor.value, null);
10062
+ }
10063
+ return Reflect.defineProperty(target, key, descriptor);
10052
10064
  }
10053
10065
  };
10054
10066
  {
@@ -10934,7 +10946,7 @@ var Vue = (function () {
10934
10946
  }
10935
10947
 
10936
10948
  // Core API ------------------------------------------------------------------
10937
- const version = "3.2.30";
10949
+ const version = "3.2.31";
10938
10950
  /**
10939
10951
  * SSR utils for \@vue/server-renderer. Only exposed in cjs builds.
10940
10952
  * @internal