New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(angular): add opinionated mfe webpack helpers #9233
Conversation
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/nrwl/nx-dev/A4K5VxGrkCBxEw5omJjqHD5h4h3d [Deployment for 82b3017 canceled] |
This is great! It doesn't seem like there's anything Angular specific about this, so does it need to be in @nrwl/angular? I would love to use this in React apps as well. |
@ashwinGokhale It's all on the roadmap 🙂 |
b7d5c94
to
36b0737
Compare
36b0737
to
82b3017
Compare
This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request. |
Context
Currently, when generating Angular MFE Webpack Configurations we rely on
@angular-architects/module-federation
. However, what we use from this package does not involve Angular specifically.It is also not built to think exclusively about Nx Monorepos. In this regard, it is possible to improve DX for Nx Workspaces using MFEs.
It also offers a lot of flexibility, which may be useful for some use cases, however, it would be preferable to retain some additional control.
Added Behaviour
This PR adds two helper functions to replace what we require from
@angular-architects/module-federation
.The aims with these helpers are:
Results
A current Webpack host config that is generated including a single shared workspace library:
A Webpack config for a host using our new helpers: