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
Module Federation React remote cannot contain a dash in the project name #23024
Labels
Comments
AgentEnder
added
the
scope: module federation
Issues related to module federation support
label
Apr 29, 2024
For global modules I do think we need to handle this, so it will be fixed soon in a following PR. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Current Behavior
When creating a Module Federation React remote with a dash in the project name, trying to build or serve the remote leads to this Webpack error.
When trying to solve the issue by changing the format of the var identifier in the
module-federation.config.ts
of the remote and all the related references in the host, another error is thrown by Nx.We investigated the issue in the Nx source code, and it seems that Nx tries to use the var identifier name (remoteA) to retrieve the corresponding project information, instead of using the actual Nx project name (remote-a).
Expected Behavior
When creating a Module Federation React remote with a dash in the project name, the generator produces a project that can be built and served out-of-the-box.
GitHub Repo
No response
Steps to Reproduce
remote-a
toremoteA
inhost/frontend/src/assets/module-federation.manifest.json
,remote-a/frontend/module-federation.config.ts
andhost/frontend/src/app/App.tsx
.Nx Report
Failure Logs
No response
Package Manager Version
No response
Operating System
Additional Information
No response
The text was updated successfully, but these errors were encountered: