@nx/angular:setup-mf
Create Module Federation configuration files for given Angular Application.
The State of JS survey is live, featuring a monorepo tools sectionThe State of JS survey is live, featuring a monorepo tools sectionVote for us
Create Module Federation configuration files for given Angular Application.
The setup-mf generator is used to add Module Federation support to existing applications.
To convert an existing application to a host application, run the following
1nx g setup-mf myapp --mfType=host --routing=true
21nx generate setup-mf ...
2By default, Nx will search for setup-mf in the default collection provisioned in workspace.json.
You can specify the collection explicitly as follows:
1nx g @nx/angular:setup-mf ...
2Show what will be generated without writing to disk:
1nx g setup-mf ... --dry-run
2The name of the application to generate the Module Federation configuration for.
remotehost, remoteType of application to generate the Module Federation configuration for.
Generate a routing setup to allow a host application to route to the remote application.
The project name of the associated E2E project for the application. This is only required for Cypress E2E projects that do not follow the naming convention <appName>-e2e.
staticstatic, dynamicUse either Static or Dynamic Module Federation pattern for the application.
The name of the host application that the remote application will be consumed by.
The port at which the remote application should be served.
The prefix to use for any generated component.
A list of remote application names that the host application should consume.
falseDo not set up E2E related config.
trueWhether the application is a standalone application.
falseWhether or not to configure the ESLint parserOptions.project option. We do not do this by default for lint performance reasons.
trueWhether the module federation configuration and webpack configuration files should use TS.
Skip formatting the workspace after the generator completes.
falseDo not add dependencies to package.json.