originjs / vite-plugin-federation

Module Federation for vite & rollup
Other
2.23k stars 234 forks source link

The example of "vue3-demo-esm-shared-store" is not working on 1.2.x version #484

Open xhhcyh opened 1 year ago

xhhcyh commented 1 year ago

Versions

Reproduction

https://github.com/originjs/vite-plugin-federation/tree/main/packages/examples/vue3-demo-esm-shared-store

Additional Details
It's related to #315 "There's an example with shared stores?"

Steps to reproduce

  1. Copy [vue3-demo-esm-shared-store] to a new place
  2. vue3-demo-esm-shared-store/remote-A/package.json:change "vite-plugin-top-level-await": "^1.1.1" to "vite-plugin-top-level-await": "1.1.1"
  3. vue3-demo-esm-shared-store/remote-B/package.json:change "vite-plugin-top-level-await": "^1.1.1" to "vite-plugin-top-level-await": "1.1.1"
  4. vue3-demo-esm-shared-store/package.json:change "@originjs/vite-plugin-federation": "workspace:*" to "@originjs/vite-plugin-federation": "1.2.x" (1.2.x means:1.2.0~1.2.3)
  5. yarn install
  6. pnpm run build
  7. pnpm run serve

What is Expected?

The example is supposed to work correctly.

What is actually happening?

image

when using the newest version(1.2.3) of [vite-plugin-federation] plugin. The error occured like above. The example is working on v1.1.14 version that I have tried. But not working on all version of 1.2

lmm1990 commented 6 months ago

same problem. Have you solved it?

likang329 commented 1 month ago

大佬解决了吗?或者怎么处理pinia中的数据共享啊

Issues-translate-bot commented 1 month ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Has the boss solved it? Or how to handle data sharing in pinia?