From: Evan You Date: Mon, 28 Oct 2019 00:45:54 +0000 (-0400) Subject: chore: comment on cloneVNode implementation [ci skip] X-Git-Tag: v3.0.0-alpha.0~295 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a8aa3289078de09f27527c374b602d63ff6c0738;p=thirdparty%2Fvuejs%2Fcore.git chore: comment on cloneVNode implementation [ci skip] --- diff --git a/packages/runtime-core/src/vnode.ts b/packages/runtime-core/src/vnode.ts index 3293315c17..98cdc0211f 100644 --- a/packages/runtime-core/src/vnode.ts +++ b/packages/runtime-core/src/vnode.ts @@ -233,6 +233,8 @@ export function createVNode( } export function cloneVNode(vnode: VNode, extraProps?: Data): VNode { + // This is intentionally NOT using spread or extend to avoid the runtime + // key enumeration cost. return { _isVNode: true, type: vnode.type,