4

I have multiple small Singla SPA Vue apps working together, there is also a NPM package with Vue components, some functions, etc. Basically that NPM package contains shared code used across all Single SPA apps.

Now the problem is that if Single SPA 1 register components from NPM package and Single SPA 2 do same, but both use different versions of package then one that register first (or last, not sure order but it does not matter) will force same version both SPA, so both use newest or oldest instead of both using version installed. Most likely Vue.component('xxx', xxx) register it globally.

Now my question is if there exist a way to register component only in a scope of Single SPA instead of globally.

I use latest https://www.npmjs.com/package/single-spa?activeTab=versions (5.9.3)

Zixav
  • 131
  • 1

0 Answers0