Open Ravi-Royal-143 opened 2 years ago
I tried shell app with angular app version 13 and remote app with angular 12 that works absolutely fine. But other way is throwing same error as you mentioned.
Hi,
yes, that should be possible. Just make sure, you have the newest version of this Plugin. However, if you have Angular 12, you need to install ngx-build-plus version 12 (if you have Angular 13, you need to install ngx-build-plus version 13).
Also, for loading Angular 12, use type: 'script' and for loading Angular 13 use type: 'module'.
Please note, in this case you have also to bootstrap both Angular versions. This can come with some difficulties. This package can help here:
https://www.npmjs.com/package/@angular-architects/module-federation-tools
Best wishes, Manfred
Hi attached screenshot for reference
Repo: for shell app: angular12-microfrontends for child app: https://github.com/manfredsteyer/module-federation-plugin-example
To start the app change done: 1) In module-federation-plugin-example changed all ports from 3000 to 4201. 2) In module-federation-plugin-example -> npm run start:mfe1 3) In angular12-microfrontend -> npm run start:shell
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' )