From: Evan You Date: Thu, 27 Feb 2020 02:29:41 +0000 (-0500) Subject: test: fix options usage of reactive X-Git-Tag: v3.0.0-alpha.8~28 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=5d952cc051edf3a4cd07e38a022e22819b2a6e50;p=thirdparty%2Fvuejs%2Fcore.git test: fix options usage of reactive --- diff --git a/packages/runtime-core/src/apiOptions.ts b/packages/runtime-core/src/apiOptions.ts index e4daea84b6..ab0749f72e 100644 --- a/packages/runtime-core/src/apiOptions.ts +++ b/packages/runtime-core/src/apiOptions.ts @@ -249,8 +249,9 @@ export function applyOptions( } = options const renderContext = - instance.renderContext === EMPTY_OBJ - ? (instance.renderContext = {}) + instance.renderContext === EMPTY_OBJ && + (computedOptions || methods || watchOptions || injectOptions) + ? (instance.renderContext = reactive({})) : instance.renderContext const globalMixins = instance.appContext.mixins