From 3116b5d6c3628c88a290c487bc0a21c63689c606 Mon Sep 17 00:00:00 2001 From: Evan You Date: Thu, 12 Dec 2019 11:44:18 -0500 Subject: [PATCH] fix(runtime-core): initialize renderCache if not present --- packages/runtime-core/src/componentProxy.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/runtime-core/src/componentProxy.ts b/packages/runtime-core/src/componentProxy.ts index 0638b9bd..02629fdd 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,