From c32834fc2e4e1247494fc9064d9708f40d646992 Mon Sep 17 00:00:00 2001 From: Daniel Roe Date: Wed, 11 Sep 2024 21:09:33 +0100 Subject: [PATCH] chore: type --- .../nuxt/src/components/runtime/client-delayed-component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nuxt/src/components/runtime/client-delayed-component.ts b/packages/nuxt/src/components/runtime/client-delayed-component.ts index e318dad3b8..0bef95e2f5 100644 --- a/packages/nuxt/src/components/runtime/client-delayed-component.ts +++ b/packages/nuxt/src/components/runtime/client-delayed-component.ts @@ -69,7 +69,7 @@ export const createLazyMediaComponent = (loader: AsyncComponentLoader) => { const instance = getCurrentInstance()! onNuxtReady(() => ready.value = true) // This one, unlike others, can cause a hydration mismatch even a whole minute after the page loads. Given a query of min-width: 1200px, with a small window, the moment the window expands to at least 1200 it hydrates and causes a hydration mismatch. - return () => ready.value ? h(defineAsyncComponent({ loader, hydrate: hydrateOnMediaQuery(attrs.hydrate ?? '(min-width: 1px)') })) : nuxt.isHydrating && instance.vnode.el ? h('div', attrs) : null + return () => ready.value ? h(defineAsyncComponent({ loader, hydrate: hydrateOnMediaQuery(attrs.hydrate as string ?? '(min-width: 1px)') })) : nuxt.isHydrating && instance.vnode.el ? h('div', attrs) : null }, }) }