reactjs - 单个 SPA React 应用程序微前端
问题描述
我有在创建反应应用程序中开发的反应应用程序。
现在我正在使用单个 spa 集成微前端。
我已将 React 应用程序转换为单个 spa。工作正常。
问题 :
我有另一个在 CRA 中开发的反应应用程序(创建反应应用程序)。这个应用程序也与 Single SPA 集成
现在我需要与主应用程序集成。示例代码:
https://github.com/gokulwebdeveloper/single-spa
registerApplication(
'weather',
() => System.import('http://localhost:8500/sample-sample.js'),
() => location.pathname === "/weather" || location.pathname === "/" ? true : false
);
请帮我修复。
解决方案
推荐阅读
- python - 在 Python 中绘制来自两个不同数据帧的相同变量的图形
- java - weka , java , MultilabelArffFileStream.java
- node.js - 为什么从 worker 到 master 的 IPC 消息的时间很慢?(>400ms)
- kibana - Kibana UI 无法在 Linux 上加载
- php - 如何使用插件编辑 moodle 核心文件?
- c# - IBMDB2 OLeDB 连接异常“尝试读取或写入受保护的内存。这通常表明其他内存已损坏”
- wordpress - wordpress - 如何在functions.php中获取当前术语
- c# - VS 17 循环遍历,调用 API,注入 JSON
- android - Android的步进器(增加/减少值)控制?
- linux - 如何使用 GDB 提取结构成员的值