module-federation / module-federation-examples

Implementation examples of module federation , by the creators of module federation
https://module-federation.io/
MIT License
5.57k stars 1.74k forks source link

Is it possible to use the shell app angular version @12 & other child/shared mfe's @v13 #1834

Closed Ravi-Royal-143 closed 2 years ago

Ravi-Royal-143 commented 2 years ago

I am using child mfe which needs to be updated to the angular version 13 but the shell app is still in angular version 12 which will be updated later on is this possible. it's throwing some console error "Cannot read properties of undefined ( reading 'init' )

ScriptedAlchemy commented 2 years ago

Probably can but you'd likely need to load 2 copies of angular. And mount them as separate apps with adapters to proxy data back and forth

Ravi-Royal-143 commented 2 years ago

Error screenshot image

Repo: for shell app: angular12-microfrontends for child app: https://github.com/manfredsteyer/module-federation-plugin-example

To start the app change done:

In module-federation-plugin-example changed all ports from 3000 to 4201. In module-federation-plugin-example -> npm run start:mfe1 In angular12-microfrontend -> npm run start:shell