mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
fix: use VNode type
This commit is contained in:
parent
580d9bd463
commit
e2d0350698
@ -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)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user