refactor: simplify static content insertion

This commit is contained in:
Evan You
2021-07-09 16:18:36 -04:00
parent 5df7dfcd71
commit c0db807844
4 changed files with 30 additions and 94 deletions

View File

@@ -168,7 +168,6 @@ export interface VNode<
target: HostElement | null // teleport target
targetAnchor: HostNode | null // teleport target anchor
staticCount?: number // number of elements contained in a static vnode
staticCache?: HostNode[] // cache of parsed static nodes for faster repeated insertions
// suspense
suspense: SuspenseBoundary | null
@@ -521,7 +520,6 @@ export function cloneVNode<T, U>(
target: vnode.target,
targetAnchor: vnode.targetAnchor,
staticCount: vnode.staticCount,
staticCache: vnode.staticCache,
shapeFlag: vnode.shapeFlag,
// if the vnode is cloned with extra props, we can no longer assume its
// existing patch flag to be reliable and need to add the FULL_PROPS flag.