You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if(container){// using appName as cache for internal experimental scenarioif($$cacheLifecycleByAppName){constparcelConfigGetterPromise=appConfigPromiseGetterMap.get(name);if(parcelConfigGetterPromise)returnwrapParcelConfigForRemount((awaitparcelConfigGetterPromise)(container));}if(containerXPath){constparcelConfigGetterPromise=appConfigPromiseGetterMap.get(appContainerXPathKey);if(parcelConfigGetterPromise)returnwrapParcelConfigForRemount((awaitparcelConfigGetterPromise)(container));}}
What happens?
当多个子应用来回切换时,从第二个子应用切回第一个子应用,子应用的appName会自动加1
Mini Showcase Repository(REQUIRED)
最小重现
How To Reproduce
分析原因:
因为子应用
app1
第二次打开时,主应用的DOM结构发生了变化,导致qiankun中的计算出的containerXPath
会发生变化,从而导致appConfigPromiseGetterMap
获取不到缓存,重新执行了loadApp
,获取到的appInstanceId
会自动+1源码定位
请问如何解决主应用 DOM 结构变化导致的 containerXPath 不同所产生的问题呢
Context
The text was updated successfully, but these errors were encountered: