@vue/compat 3.5.18 → 3.5.20

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/compat v3.5.18
2
+ * @vue/compat v3.5.20
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -56,10 +56,10 @@ const isBuiltInDirective = /* @__PURE__ */ makeMap(
56
56
  );
57
57
  const cacheStringFunction = (fn) => {
58
58
  const cache = /* @__PURE__ */ Object.create(null);
59
- return (str) => {
59
+ return ((str) => {
60
60
  const hit = cache[str];
61
61
  return hit || (cache[str] = fn(str));
62
- };
62
+ });
63
63
  };
64
64
  const camelizeRE = /-(\w)/g;
65
65
  const camelize = cacheStringFunction(
@@ -1168,7 +1168,7 @@ const arrayInstrumentations = {
1168
1168
  join(separator) {
1169
1169
  return reactiveReadArray(this).join(separator);
1170
1170
  },
1171
- // keys() iterator only reads `length`, no optimisation required
1171
+ // keys() iterator only reads `length`, no optimization required
1172
1172
  lastIndexOf(...args) {
1173
1173
  return searchProxy(this, "lastIndexOf", args);
1174
1174
  },
@@ -1369,7 +1369,13 @@ class MutableReactiveHandler extends BaseReactiveHandler {
1369
1369
  }
1370
1370
  if (!isArray(target) && isRef(oldValue) && !isRef(value)) {
1371
1371
  if (isOldValueReadonly) {
1372
- return false;
1372
+ if (!!(process.env.NODE_ENV !== "production")) {
1373
+ warn$2(
1374
+ `Set operation on key "${String(key)}" failed: target is readonly.`,
1375
+ target[key]
1376
+ );
1377
+ }
1378
+ return true;
1373
1379
  } else {
1374
1380
  oldValue.value = value;
1375
1381
  return true;
@@ -1514,7 +1520,7 @@ function createInstrumentations(readonly, shallow) {
1514
1520
  get size() {
1515
1521
  const target = this["__v_raw"];
1516
1522
  !readonly && track(toRaw(target), "iterate", ITERATE_KEY);
1517
- return Reflect.get(target, "size", target);
1523
+ return target.size;
1518
1524
  },
1519
1525
  has(key) {
1520
1526
  const target = this["__v_raw"];
@@ -2747,7 +2753,9 @@ function rerender(id, newRender) {
2747
2753
  }
2748
2754
  instance.renderCache = [];
2749
2755
  isHmrUpdating = true;
2750
- instance.update();
2756
+ if (!(instance.job.flags & 8)) {
2757
+ instance.update();
2758
+ }
2751
2759
  isHmrUpdating = false;
2752
2760
  });
2753
2761
  }
@@ -4343,7 +4351,7 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
4343
4351
  const refs = owner.refs === EMPTY_OBJ ? owner.refs = {} : owner.refs;
4344
4352
  const setupState = owner.setupState;
4345
4353
  const rawSetupState = toRaw(setupState);
4346
- const canSetSetupRef = setupState === EMPTY_OBJ ? () => false : (key) => {
4354
+ const canSetSetupRef = setupState === EMPTY_OBJ ? NO : (key) => {
4347
4355
  if (!!(process.env.NODE_ENV !== "production")) {
4348
4356
  if (hasOwn(rawSetupState, key) && !isRef(rawSetupState[key])) {
4349
4357
  warn$1(
@@ -4356,6 +4364,9 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
4356
4364
  }
4357
4365
  return hasOwn(rawSetupState, key);
4358
4366
  };
4367
+ const canSetRef = (ref2) => {
4368
+ return !!!(process.env.NODE_ENV !== "production") || !knownTemplateRefs.has(ref2);
4369
+ };
4359
4370
  if (oldRef != null && oldRef !== ref) {
4360
4371
  if (isString(oldRef)) {
4361
4372
  refs[oldRef] = null;
@@ -4363,7 +4374,11 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
4363
4374
  setupState[oldRef] = null;
4364
4375
  }
4365
4376
  } else if (isRef(oldRef)) {
4366
- oldRef.value = null;
4377
+ if (canSetRef(oldRef)) {
4378
+ oldRef.value = null;
4379
+ }
4380
+ const oldRawRefAtom = oldRawRef;
4381
+ if (oldRawRefAtom.k) refs[oldRawRefAtom.k] = null;
4367
4382
  }
4368
4383
  }
4369
4384
  if (isFunction(ref)) {
@@ -4374,7 +4389,7 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
4374
4389
  if (_isString || _isRef) {
4375
4390
  const doSet = () => {
4376
4391
  if (rawRef.f) {
4377
- const existing = _isString ? canSetSetupRef(ref) ? setupState[ref] : refs[ref] : ref.value;
4392
+ const existing = _isString ? canSetSetupRef(ref) ? setupState[ref] : refs[ref] : canSetRef(ref) || !rawRef.k ? ref.value : refs[rawRef.k];
4378
4393
  if (isUnmount) {
4379
4394
  isArray(existing) && remove(existing, refValue);
4380
4395
  } else {
@@ -4385,8 +4400,11 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
4385
4400
  setupState[ref] = refs[ref];
4386
4401
  }
4387
4402
  } else {
4388
- ref.value = [refValue];
4389
- if (rawRef.k) refs[rawRef.k] = ref.value;
4403
+ const newVal = [refValue];
4404
+ if (canSetRef(ref)) {
4405
+ ref.value = newVal;
4406
+ }
4407
+ if (rawRef.k) refs[rawRef.k] = newVal;
4390
4408
  }
4391
4409
  } else if (!existing.includes(refValue)) {
4392
4410
  existing.push(refValue);
@@ -4398,7 +4416,9 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
4398
4416
  setupState[ref] = value;
4399
4417
  }
4400
4418
  } else if (_isRef) {
4401
- ref.value = value;
4419
+ if (canSetRef(ref)) {
4420
+ ref.value = value;
4421
+ }
4402
4422
  if (rawRef.k) refs[rawRef.k] = value;
4403
4423
  } else if (!!(process.env.NODE_ENV !== "production")) {
4404
4424
  warn$1("Invalid template ref type:", ref, `(${typeof ref})`);
@@ -6169,7 +6189,7 @@ function legacyRenderSlot(instance, name, fallback, props, bindObject) {
6169
6189
  }
6170
6190
  return renderSlot(instance.slots, name, props, fallback && (() => fallback));
6171
6191
  }
6172
- function legacyresolveScopedSlots(fns, raw, hasDynamicKeys) {
6192
+ function legacyResolveScopedSlots(fns, raw, hasDynamicKeys) {
6173
6193
  return createSlots(
6174
6194
  raw || { $stable: !hasDynamicKeys },
6175
6195
  mapKeyToName(fns)
@@ -6336,7 +6356,7 @@ function installCompatInstanceProperties(map) {
6336
6356
  _b: () => legacyBindObjectProps,
6337
6357
  _v: () => createTextVNode,
6338
6358
  _e: () => createCommentVNode,
6339
- _u: () => legacyresolveScopedSlots,
6359
+ _u: () => legacyResolveScopedSlots,
6340
6360
  _g: () => legacyBindObjectListeners,
6341
6361
  _d: () => legacyBindDynamicKeys,
6342
6362
  _p: () => legacyPrependModifier
@@ -6507,10 +6527,10 @@ const PublicInstanceProxyHandlers = {
6507
6527
  return true;
6508
6528
  },
6509
6529
  has({
6510
- _: { data, setupState, accessCache, ctx, appContext, propsOptions }
6530
+ _: { data, setupState, accessCache, ctx, appContext, propsOptions, type }
6511
6531
  }, key) {
6512
- let normalizedProps;
6513
- return !!accessCache[key] || data !== EMPTY_OBJ && hasOwn(data, key) || hasSetupBinding(setupState, key) || (normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key) || hasOwn(ctx, key) || hasOwn(publicPropertiesMap, key) || hasOwn(appContext.config.globalProperties, key);
6532
+ let normalizedProps, cssModules;
6533
+ return !!(accessCache[key] || data !== EMPTY_OBJ && key[0] !== "$" && hasOwn(data, key) || hasSetupBinding(setupState, key) || (normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key) || hasOwn(ctx, key) || hasOwn(publicPropertiesMap, key) || hasOwn(appContext.config.globalProperties, key) || (cssModules = type.__cssModules) && cssModules[key]);
6514
6534
  },
6515
6535
  defineProperty(target, key, descriptor) {
6516
6536
  if (descriptor.get != null) {
@@ -7257,7 +7277,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
7257
7277
  return vm;
7258
7278
  }
7259
7279
  }
7260
- Vue.version = `2.6.14-compat:${"3.5.18"}`;
7280
+ Vue.version = `2.6.14-compat:${"3.5.20"}`;
7261
7281
  Vue.config = singletonApp.config;
7262
7282
  Vue.use = (plugin, ...options) => {
7263
7283
  if (plugin && isFunction(plugin.install)) {
@@ -7271,22 +7291,22 @@ function createCompatVue$1(createApp, createSingletonApp) {
7271
7291
  singletonApp.mixin(m);
7272
7292
  return Vue;
7273
7293
  };
7274
- Vue.component = (name, comp) => {
7294
+ Vue.component = ((name, comp) => {
7275
7295
  if (comp) {
7276
7296
  singletonApp.component(name, comp);
7277
7297
  return Vue;
7278
7298
  } else {
7279
7299
  return singletonApp.component(name);
7280
7300
  }
7281
- };
7282
- Vue.directive = (name, dir) => {
7301
+ });
7302
+ Vue.directive = ((name, dir) => {
7283
7303
  if (dir) {
7284
7304
  singletonApp.directive(name, dir);
7285
7305
  return Vue;
7286
7306
  } else {
7287
7307
  return singletonApp.directive(name);
7288
7308
  }
7289
- };
7309
+ });
7290
7310
  Vue.options = { _base: Vue };
7291
7311
  let cid = 1;
7292
7312
  Vue.cid = cid;
@@ -7349,14 +7369,14 @@ function createCompatVue$1(createApp, createSingletonApp) {
7349
7369
  assertCompatEnabled("GLOBAL_OBSERVABLE", null);
7350
7370
  return reactive(target);
7351
7371
  };
7352
- Vue.filter = (name, filter) => {
7372
+ Vue.filter = ((name, filter) => {
7353
7373
  if (filter) {
7354
7374
  singletonApp.filter(name, filter);
7355
7375
  return Vue;
7356
7376
  } else {
7357
7377
  return singletonApp.filter(name);
7358
7378
  }
7359
- };
7379
+ });
7360
7380
  const util = {
7361
7381
  warn: !!(process.env.NODE_ENV !== "production") ? warn$1 : NOOP,
7362
7382
  extend,
@@ -8352,7 +8372,7 @@ function isBoolean(...args) {
8352
8372
  return args.some((elem) => elem.toLowerCase() === "boolean");
8353
8373
  }
8354
8374
 
8355
- const isInternalKey = (key) => key === "_" || key === "__" || key === "_ctx" || key === "$stable";
8375
+ const isInternalKey = (key) => key === "_" || key === "_ctx" || key === "$stable";
8356
8376
  const normalizeSlotValue = (value) => isArray(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
8357
8377
  const normalizeSlot = (key, rawSlot, ctx) => {
8358
8378
  if (rawSlot._n) {
@@ -8406,8 +8426,6 @@ const assignSlots = (slots, children, optimized) => {
8406
8426
  const initSlots = (instance, children, optimized) => {
8407
8427
  const slots = instance.slots = createInternalObject();
8408
8428
  if (instance.vnode.shapeFlag & 32) {
8409
- const cacheIndexes = children.__;
8410
- if (cacheIndexes) def(slots, "__", cacheIndexes, true);
8411
8429
  const type = children._;
8412
8430
  if (type) {
8413
8431
  assignSlots(slots, children, optimized);
@@ -8468,12 +8486,10 @@ function endMeasure(instance, type) {
8468
8486
  if (instance.appContext.config.performance && isSupported()) {
8469
8487
  const startTag = `vue-${type}-${instance.uid}`;
8470
8488
  const endTag = startTag + `:end`;
8489
+ const measureName = `<${formatComponentName(instance, instance.type)}> ${type}`;
8471
8490
  perf.mark(endTag);
8472
- perf.measure(
8473
- `<${formatComponentName(instance, instance.type)}> ${type}`,
8474
- startTag,
8475
- endTag
8476
- );
8491
+ perf.measure(measureName, startTag, endTag);
8492
+ perf.clearMeasures(measureName);
8477
8493
  perf.clearMarks(startTag);
8478
8494
  perf.clearMarks(endTag);
8479
8495
  }
@@ -9728,6 +9744,12 @@ function baseCreateRenderer(options, createHydrationFns) {
9728
9744
  }
9729
9745
  };
9730
9746
  const performLeave = () => {
9747
+ if (el._isLeaving) {
9748
+ el[leaveCbKey](
9749
+ true
9750
+ /* cancelled */
9751
+ );
9752
+ }
9731
9753
  leave(el, () => {
9732
9754
  remove2();
9733
9755
  afterLeave && afterLeave();
@@ -9873,27 +9895,12 @@ function baseCreateRenderer(options, createHydrationFns) {
9873
9895
  if (!!(process.env.NODE_ENV !== "production") && instance.type.__hmrId) {
9874
9896
  unregisterHMR(instance);
9875
9897
  }
9876
- const {
9877
- bum,
9878
- scope,
9879
- job,
9880
- subTree,
9881
- um,
9882
- m,
9883
- a,
9884
- parent,
9885
- slots: { __: slotCacheKeys }
9886
- } = instance;
9898
+ const { bum, scope, job, subTree, um, m, a } = instance;
9887
9899
  invalidateMount(m);
9888
9900
  invalidateMount(a);
9889
9901
  if (bum) {
9890
9902
  invokeArrayFns(bum);
9891
9903
  }
9892
- if (parent && isArray(slotCacheKeys)) {
9893
- slotCacheKeys.forEach((v) => {
9894
- parent.renderCache[v] = void 0;
9895
- });
9896
- }
9897
9904
  if (isCompatEnabled$1("INSTANCE_EVENT_HOOKS", instance)) {
9898
9905
  instance.emit("hook:beforeDestroy");
9899
9906
  }
@@ -9914,12 +9921,6 @@ function baseCreateRenderer(options, createHydrationFns) {
9914
9921
  queuePostRenderEffect(() => {
9915
9922
  instance.isUnmounted = true;
9916
9923
  }, parentSuspense);
9917
- if (parentSuspense && parentSuspense.pendingBranch && !parentSuspense.isUnmounted && instance.asyncDep && !instance.asyncResolved && instance.suspenseId === parentSuspense.pendingId) {
9918
- parentSuspense.deps--;
9919
- if (parentSuspense.deps === 0) {
9920
- parentSuspense.resolve();
9921
- }
9922
- }
9923
9924
  if (!!(process.env.NODE_ENV !== "production") || __VUE_PROD_DEVTOOLS__) {
9924
9925
  devtoolsComponentRemoved(instance);
9925
9926
  }
@@ -10020,7 +10021,8 @@ function traverseStaticChildren(n1, n2, shallow = false) {
10020
10021
  if (!shallow && c2.patchFlag !== -2)
10021
10022
  traverseStaticChildren(c1, c2);
10022
10023
  }
10023
- if (c2.type === Text) {
10024
+ if (c2.type === Text && // avoid cached text nodes retaining detached dom nodes
10025
+ c2.patchFlag !== -1) {
10024
10026
  c2.el = c1.el;
10025
10027
  }
10026
10028
  if (c2.type === Comment && !c2.el) {
@@ -12479,7 +12481,7 @@ function isMemoSame(cached, memo) {
12479
12481
  return true;
12480
12482
  }
12481
12483
 
12482
- const version = "3.5.18";
12484
+ const version = "3.5.20";
12483
12485
  const warn = !!(process.env.NODE_ENV !== "production") ? warn$1 : NOOP;
12484
12486
  const ErrorTypeStrings = ErrorTypeStrings$1 ;
12485
12487
  const devtools = !!(process.env.NODE_ENV !== "production") || true ? devtools$1 : void 0;
@@ -12923,6 +12925,8 @@ function patchClass(el, value, isSVG) {
12923
12925
  const vShowOriginalDisplay = Symbol("_vod");
12924
12926
  const vShowHidden = Symbol("_vsh");
12925
12927
  const vShow = {
12928
+ // used for prop mismatch check during hydration
12929
+ name: "show",
12926
12930
  beforeMount(el, { value }, { transition }) {
12927
12931
  el[vShowOriginalDisplay] = el.style.display === "none" ? "" : el.style.display;
12928
12932
  if (transition && value) {
@@ -12956,9 +12960,6 @@ const vShow = {
12956
12960
  setDisplay(el, value);
12957
12961
  }
12958
12962
  };
12959
- if (!!(process.env.NODE_ENV !== "production")) {
12960
- vShow.name = "show";
12961
- }
12962
12963
  function setDisplay(el, value) {
12963
12964
  el.style.display = value ? el[vShowOriginalDisplay] : "none";
12964
12965
  el[vShowHidden] = !value;
@@ -13424,10 +13425,10 @@ function defineCustomElement(options, extraOptions, _createApp) {
13424
13425
  VueCustomElement.def = Comp;
13425
13426
  return VueCustomElement;
13426
13427
  }
13427
- /*! #__NO_SIDE_EFFECTS__ */
13428
- const defineSSRCustomElement = /* @__NO_SIDE_EFFECTS__ */ (options, extraOptions) => {
13428
+
13429
+ const defineSSRCustomElement = (/* @__NO_SIDE_EFFECTS__ */ (options, extraOptions) => {
13429
13430
  return /* @__PURE__ */ defineCustomElement(options, extraOptions, createSSRApp);
13430
- };
13431
+ });
13431
13432
  const BaseClass = typeof HTMLElement !== "undefined" ? HTMLElement : class {
13432
13433
  };
13433
13434
  class VueElement extends BaseClass {
@@ -14297,13 +14298,13 @@ const modifierGuards = {
14297
14298
  const withModifiers = (fn, modifiers) => {
14298
14299
  const cache = fn._withMods || (fn._withMods = {});
14299
14300
  const cacheKey = modifiers.join(".");
14300
- return cache[cacheKey] || (cache[cacheKey] = (event, ...args) => {
14301
+ return cache[cacheKey] || (cache[cacheKey] = ((event, ...args) => {
14301
14302
  for (let i = 0; i < modifiers.length; i++) {
14302
14303
  const guard = modifierGuards[modifiers[i]];
14303
14304
  if (guard && guard(event, modifiers)) return;
14304
14305
  }
14305
14306
  return fn(event, ...args);
14306
- });
14307
+ }));
14307
14308
  };
14308
14309
  const keyNames = {
14309
14310
  esc: "escape",
@@ -14333,7 +14334,7 @@ const withKeys = (fn, modifiers) => {
14333
14334
  }
14334
14335
  const cache = fn._withKeys || (fn._withKeys = {});
14335
14336
  const cacheKey = modifiers.join(".");
14336
- return cache[cacheKey] || (cache[cacheKey] = (event) => {
14337
+ return cache[cacheKey] || (cache[cacheKey] = ((event) => {
14337
14338
  if (!("key" in event)) {
14338
14339
  return;
14339
14340
  }
@@ -14363,7 +14364,7 @@ const withKeys = (fn, modifiers) => {
14363
14364
  }
14364
14365
  }
14365
14366
  }
14366
- });
14367
+ }));
14367
14368
  };
14368
14369
 
14369
14370
  const rendererOptions = /* @__PURE__ */ extend({ patchProp }, nodeOps);
@@ -14377,13 +14378,13 @@ function ensureHydrationRenderer() {
14377
14378
  enabledHydration = true;
14378
14379
  return renderer;
14379
14380
  }
14380
- const render = (...args) => {
14381
+ const render = ((...args) => {
14381
14382
  ensureRenderer().render(...args);
14382
- };
14383
- const hydrate = (...args) => {
14383
+ });
14384
+ const hydrate = ((...args) => {
14384
14385
  ensureHydrationRenderer().hydrate(...args);
14385
- };
14386
- const createApp = (...args) => {
14386
+ });
14387
+ const createApp = ((...args) => {
14387
14388
  const app = ensureRenderer().createApp(...args);
14388
14389
  if (!!(process.env.NODE_ENV !== "production")) {
14389
14390
  injectNativeTagCheck(app);
@@ -14420,8 +14421,8 @@ const createApp = (...args) => {
14420
14421
  return proxy;
14421
14422
  };
14422
14423
  return app;
14423
- };
14424
- const createSSRApp = (...args) => {
14424
+ });
14425
+ const createSSRApp = ((...args) => {
14425
14426
  const app = ensureHydrationRenderer().createApp(...args);
14426
14427
  if (!!(process.env.NODE_ENV !== "production")) {
14427
14428
  injectNativeTagCheck(app);
@@ -14435,7 +14436,7 @@ const createSSRApp = (...args) => {
14435
14436
  }
14436
14437
  };
14437
14438
  return app;
14438
- };
14439
+ });
14439
14440
  function resolveRootNamespace(container) {
14440
14441
  if (container instanceof SVGElement) {
14441
14442
  return "svg";
@@ -16984,7 +16985,6 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
16984
16985
  }
16985
16986
  }
16986
16987
  let cachedAsArray = false;
16987
- const slotCacheKeys = [];
16988
16988
  if (toCache.length === children.length && node.type === 1) {
16989
16989
  if (node.tagType === 0 && node.codegenNode && node.codegenNode.type === 13 && isArray(node.codegenNode.children)) {
16990
16990
  node.codegenNode.children = getCacheExpression(
@@ -16994,7 +16994,6 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
16994
16994
  } else if (node.tagType === 1 && node.codegenNode && node.codegenNode.type === 13 && node.codegenNode.children && !isArray(node.codegenNode.children) && node.codegenNode.children.type === 15) {
16995
16995
  const slot = getSlotNode(node.codegenNode, "default");
16996
16996
  if (slot) {
16997
- slotCacheKeys.push(context.cached.length);
16998
16997
  slot.returns = getCacheExpression(
16999
16998
  createArrayExpression(slot.returns)
17000
16999
  );
@@ -17004,7 +17003,6 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
17004
17003
  const slotName = findDir(node, "slot", true);
17005
17004
  const slot = slotName && slotName.arg && getSlotNode(parent.codegenNode, slotName.arg);
17006
17005
  if (slot) {
17007
- slotCacheKeys.push(context.cached.length);
17008
17006
  slot.returns = getCacheExpression(
17009
17007
  createArrayExpression(slot.returns)
17010
17008
  );
@@ -17014,23 +17012,12 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
17014
17012
  }
17015
17013
  if (!cachedAsArray) {
17016
17014
  for (const child of toCache) {
17017
- slotCacheKeys.push(context.cached.length);
17018
17015
  child.codegenNode = context.cache(child.codegenNode);
17019
17016
  }
17020
17017
  }
17021
- if (slotCacheKeys.length && node.type === 1 && node.tagType === 1 && node.codegenNode && node.codegenNode.type === 13 && node.codegenNode.children && !isArray(node.codegenNode.children) && node.codegenNode.children.type === 15) {
17022
- node.codegenNode.children.properties.push(
17023
- createObjectProperty(
17024
- `__`,
17025
- createSimpleExpression(JSON.stringify(slotCacheKeys), false)
17026
- )
17027
- );
17028
- }
17029
17018
  function getCacheExpression(value) {
17030
17019
  const exp = context.cache(value);
17031
- if (inFor && context.hmr) {
17032
- exp.needArraySpread = true;
17033
- }
17020
+ exp.needArraySpread = true;
17034
17021
  return exp;
17035
17022
  }
17036
17023
  function getSlotNode(node2, name) {
@@ -18229,7 +18216,7 @@ function processIf(node, dir, context, processCodegen) {
18229
18216
  continue;
18230
18217
  }
18231
18218
  if (sibling && sibling.type === 9) {
18232
- if (dir.name === "else-if" && sibling.branches[sibling.branches.length - 1].condition === void 0) {
18219
+ if ((dir.name === "else-if" || dir.name === "else") && sibling.branches[sibling.branches.length - 1].condition === void 0) {
18233
18220
  context.onError(
18234
18221
  createCompilerError(30, node.loc)
18235
18222
  );
@@ -19927,7 +19914,7 @@ const seen = /* @__PURE__ */ new WeakSet();
19927
19914
  const transformMemo = (node, context) => {
19928
19915
  if (node.type === 1) {
19929
19916
  const dir = findDir(node, "memo");
19930
- if (!dir || seen.has(node)) {
19917
+ if (!dir || seen.has(node) || context.inSSR) {
19931
19918
  return;
19932
19919
  }
19933
19920
  seen.add(node);