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')