From f9555247de7c0a91c1c3bf0e0eb41b4d1fc4f616 Mon Sep 17 00:00:00 2001 From: weiqingyu <252352801@qq.com> Date: Thu, 20 Feb 2025 18:23:42 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20adapter.ts/updateElementInfo=E5=BD=93a?= =?UTF-8?q?=E6=A0=87=E7=AD=BEconfigurable=E4=B8=BAfalse=E5=AF=BC=E8=87=B4?= =?UTF-8?q?=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/sandbox/adapter.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/sandbox/adapter.ts b/src/sandbox/adapter.ts index d3f4f400..fa8e60e6 100644 --- a/src/sandbox/adapter.ts +++ b/src/sandbox/adapter.ts @@ -157,7 +157,9 @@ export function updateElementInfo (node: T, appName: string | null): T { if (isAnchorElement(node)) { // a 标签 const microApp = AppManager.getInstance().get(appName) - if (microApp) { + const hrefDescriptor = Object.getOwnPropertyDescriptor(node, 'href') + const hrefConfigurable = hrefDescriptor?.configurable || !hrefDescriptor + if (microApp && hrefConfigurable) { props.href = { get() { return this.getAttribute('href')