From: Evan You Date: Thu, 19 May 2022 04:39:48 +0000 (+0800) Subject: chore: fix lint X-Git-Tag: v3.2.34~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=31bdde0480755bbd5427d9332682e5f7a396c301;p=thirdparty%2Fvuejs%2Fcore.git chore: fix lint --- diff --git a/packages/runtime-core/src/hydration.ts b/packages/runtime-core/src/hydration.ts index a8a568cabb..3dd9e806ef 100644 --- a/packages/runtime-core/src/hydration.ts +++ b/packages/runtime-core/src/hydration.ts @@ -55,7 +55,15 @@ export function createHydrationFunctions( const { mt: mountComponent, p: patch, - o: { patchProp, nextSibling, parentNode, remove, insert, createComment } + o: { + patchProp, + createText, + nextSibling, + parentNode, + remove, + insert, + createComment + } } = rendererInternals const hydrate: RootHydrateFunction = (vnode, container) => { @@ -113,11 +121,7 @@ export function createHydrationFunctions( // #5728 empty text node inside a slot can cause hydration failure // because the server rendered HTML won't contain a text node if (vnode.children === '') { - insert( - (vnode.el = document.createTextNode('')), - node.parentElement!, - node - ) + insert((vnode.el = createText('')), node.parentElement!, node) nextNode = node } else { nextNode = onMismatch()