From 68fb26d16e2cdb2c5a5a14ba096bf390b9880ec9 Mon Sep 17 00:00:00 2001 From: skirtle <65301168+skirtles-code@users.noreply.github.com> Date: Sun, 5 Oct 2025 18:30:03 +0100 Subject: [PATCH] refactor(runtime-core): check feature flag when forwarding `data` properties --- .../runtime-core/src/componentPublicInstance.ts | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/packages/runtime-core/src/componentPublicInstance.ts b/packages/runtime-core/src/componentPublicInstance.ts index 58c18764ee1..57d784c0e08 100644 --- a/packages/runtime-core/src/componentPublicInstance.ts +++ b/packages/runtime-core/src/componentPublicInstance.ts @@ -448,7 +448,11 @@ export const PublicInstanceProxyHandlers: ProxyHandler = { } else if (hasSetupBinding(setupState, key)) { accessCache![key] = AccessTypes.SETUP return setupState[key] - } else if (data !== EMPTY_OBJ && hasOwn(data, key)) { + } else if ( + __FEATURE_OPTIONS_API__ && + data !== EMPTY_OBJ && + hasOwn(data, key) + ) { accessCache![key] = AccessTypes.DATA return data[key] } else if ( @@ -545,7 +549,11 @@ export const PublicInstanceProxyHandlers: ProxyHandler = { ) { warn(`Cannot mutate