fix: use VNode type

This commit is contained in:
Michael Brevard 2024-04-11 00:10:54 +03:00 committed by GitHub
parent 580d9bd463
commit e2d0350698
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 3 deletions

View File

@ -1,5 +1,5 @@
import { createStaticVNode, defineComponent, getCurrentInstance, h, onBeforeUnmount, onMounted, ref } from 'vue'
import type { Component, Ref } from 'vue'
import type { Component, Ref, VNode } from 'vue'
// import ClientOnly from '#app/components/client-only'
import { useObserver } from '#app/utils'
import { getFragmentHTML } from '#app/components/utils'
@ -12,7 +12,7 @@ export const createLazyIOClientPage = (componentLoader: Component) => {
setup (_, { attrs }) {
const nuxt = useNuxtApp()
const instance = getCurrentInstance()!
let vnode: string | null = null
let vnode: VNode | null = null
if (import.meta.client && nuxt.isHydrating) {
vnode = createStaticVNode(getFragmentHTML(instance.vnode.el), 1)
}
@ -45,7 +45,7 @@ export const createLazyNetworkClientPage = (componentLoader: Component) => {
setup (_, { attrs }) {
const nuxt = useNuxtApp()
const instance = getCurrentInstance()!
let vnode: string | null = null
let vnode: VNode | null = null
if (import.meta.client && nuxt.isHydrating) {
vnode = createStaticVNode(getFragmentHTML(instance.vnode.el), 1)
}