我正在使用带有 Angular 10 应用程序的单水疗中心。路由有问题,当我使用“activeWhen:[”/“]”加载应用程序时,它工作正常,但如果我添加路由,我会收到“404(未找到)”错误。这是我的配置,有什么问题吗?
<script>
Promise.all([System.import('single-spa')]).then(([singleSpa]) => {
const { registerApplication, start } = singleSpa;
registerApplication({
name: "uiservice11",
app: () => System.import("uiservice11"),
activeWhen: ["/"]
});
registerApplication({
name: "uiservice1",
app: () => System.import("uiservice1"),
activeWhen: ["/home"]
});
start({
urlRerouteOnly: true,
});
});
</script>