From: daiwei Date: Thu, 3 Jul 2025 08:24:55 +0000 (+0800) Subject: chore: tweaks X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1b05c2834223ea25cd41359de7c6fce22d53f2a6;p=thirdparty%2Fvuejs%2Fcore.git chore: tweaks --- diff --git a/packages/runtime-core/src/apiAsyncComponent.ts b/packages/runtime-core/src/apiAsyncComponent.ts index 25e6fa481c..ab4ab51b66 100644 --- a/packages/runtime-core/src/apiAsyncComponent.ts +++ b/packages/runtime-core/src/apiAsyncComponent.ts @@ -126,11 +126,13 @@ export function defineAsyncComponent< ;(instance.bu || (instance.bu = [])).push(() => (patched = true)) const performHydrate = () => { // skip hydration if the component has been patched - if (__DEV__ && patched) { - warn( - `Skipping lazy hydration for component '${getComponentName(resolvedComp!) || resolvedComp!.__file}': ` + - `it was updated before lazy hydration performed.`, - ) + if (patched) { + if (__DEV__) { + warn( + `Skipping lazy hydration for component '${getComponentName(resolvedComp!) || resolvedComp!.__file}': ` + + `it was updated before lazy hydration performed.`, + ) + } return } hydrate()