diff --git a/packages/runtime-core/src/componentProxy.ts b/packages/runtime-core/src/componentProxy.ts index 0638b9bd3..02629fddd 100644 --- a/packages/runtime-core/src/componentProxy.ts +++ b/packages/runtime-core/src/componentProxy.ts @@ -51,7 +51,7 @@ const publicPropertiesMap: Record< > = { $: i => i, $el: i => i.vnode.el, - $cache: i => i.renderCache, + $cache: i => i.renderCache || (i.renderCache = []), $data: i => i.data, $props: i => i.propsProxy, $attrs: i => i.attrs,