Closed kavinluo closed 4 years ago
My teammate fixed it .
Change the root-html-file/index.html
change the code as below Add /js/ in url
"imports": { "navbar": "http://localhost:8080/js/app.js", "app1": "http://localhost:8081/js/app.js", "app2": "http://localhost:8082/js/app.js", "single-spa": "https://cdnjs.cloudflare.com/ajax/libs/single-spa/4.3.7/system/single-spa.min.js", "vue": "https://cdn.jsdelivr.net/npm/vue@2.6.10/dist/vue.js", "vue-router": "https://cdn.jsdelivr.net/npm/vue-router@3.0.7/dist/vue-router.min.js" }
我的队友修复了它。
更改root-html-file / index.html
更改代码,如下所示 在url 中添加/ js /
“ imports”:{ “ navbar”:“ http:// localhost:8080 / js / app.js ”, “ app1”:“ http:// localhost:8081 / js / app.js ”, “ app2”:“ http:// localhost:8082 / js / app.js “, ” single-spa“:” https://cdnjs.cloudflare.com/ajax/libs/single-spa/4.3.7/system/single-spa。 min.js “, ” vue“:” https://cdn.jsdelivr.net/npm/vue@2.6.10/dist/vue.js “, ” vue-router“:” https://cdn.jsdelivr。 net/npm/vue-router@3.0.7/dist/vue-router.min.js “ }
@pank789 I'm sorry, I modified it according to what you said, it hasn't been fixed, the error still remains thanks!!
I have updated the root html file in https://github.com/joeldenning/coexisting-vue-microfrontends/commit/6ffee3a0e733efdfc427b6b90716586dc893d850. Thanks @pank789 for raising the issue - it was related to a change I made recently in https://github.com/joeldenning/coexisting-vue-microfrontends/commit/9b680845fafbfee1183cd3ab8059e7e991afa04b
If you have time please tell me how to solve it, thank you very much!![image](https://user-images.githubusercontent.com/7992924/75213077-0c500a00-57c4-11ea-9734-2ad50402f962.png)
I did the following!