1

I am needing to build a Microfrontend architecture with Module Federation and my applications will be build with Vue and Angular. Precisely I will build 2 apps in Angular and 1 in Vue. My problema is there I am stuck in how to configure the webpack to expose an entire page from Angular and use it in the Vue app. Is this possible or I should use an container app with no framework to do the job of merging the apps?

I started by configuring the Vue app as the main project and having a remote import from an Angular project. However I don't seem to be having any progress in use the components from the Angular app. In my tests I could easily use Vue components in another Vue project using Module Federation Plugin but I could't do the same with the Angular components. Is there any specific configurations for Angular components to be rendered by a Vue App?

  • 1
    Likely not a good idea to build two apps powered by different frameworks together. They need different setups and may not work well under the same Webpack config. The benefits of module federation would be shared modules, while this likely is not the case. I'd consider keeping them separate. "Is there any specific configurations for Angular components to be rendered by a Vue App" - these are different frameworks, Angular comps are random pieces of code to Vue, and vice versa. Unless you use web comps, but then you'll have to deal with their limitations – Estus Flask Feb 26 '23 at 00:38
  • @EstusFlask I understand your point. In my research I encountered a way to export the mount function itself between React and Vue apps and it works pretty well. The major problem i have right know is with the angular that implements and I yet didn't find a way to render that component inside an html element other than that. – Davi Oliveira Feb 26 '23 at 19:45
  • Can you clarify what's the problem? – Estus Flask Feb 26 '23 at 19:59
  • Hi @DaviOliveira, I'm not 100 percent sure, what you try to achieve here, but did you have a look into the [astro](https://astro.build) framework? It might fit your needs? – Leif Marcus Feb 26 '23 at 20:06

0 Answers0