You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am working on a host project that loads five remote modules with Nx and Angular. After upgrading Nx to version 20.3.1 and Angular to version 19.0.7, everything builds successfully, and there are no build errors. However, when I attempt to access three of the remotes via their respective links, I encounter an issue where they do not load, whereas the other two remotes work fine.
Client-side Issue: When I click the link to load a remote, I receive a 404 Not Found error. Interestingly, if I manually click on the link in the browser, it works, and I can access the resource.
Verbose Log Output: When I run the command with --verbose, I see the following log entry:
2025-01-22 15:51:21 [webpack-dev-server] [connect-history-api-fallback] Not rewriting GET /remoteEntry.mjs because the client does not accept HTML.
Docker Setup: I am using Docker to build the project where the issue occurs. However, when I install the dependencies manually and start the project with the following script:
import { withModuleFederation } from '@nx/module-federation/angular';
import config from './module-federation.config';
/**
* DTS Plugin is disabled in Nx Workspaces as Nx already provides Typing support for Module Federation
* The DTS Plugin can be enabled by setting dts: true
* Learn more about the DTS Plugin here: https://module-federation.io/configure/dts.html
*/
export default withModuleFederation(
{
...config,
/*
* Remote overrides for production.
* Each entry is a pair of a unique name and the URL where it is deployed.
*
* e.g.
* remotes: [
* ['app1', 'https://app1.example.com'],
* ['app2', 'https://app2.example.com'],
* ]
*/
},
{ dts: false },
);
I am aware that loadRemoteModule is deprecated, but I have not yet found a suitable replacement with the new API.
I also found a simular topic: #28479 but it seems it has been close due to the lack of activity.
I tried also load all the modules independantly, and also all without one (production) one and it seems it works too with docker. So it seems that production remote is the problem, but the configuration is the same are all others...
Any insights, suggestions, or questions are welcome. I am quite perplexed by this issue and would greatly appreciate any help or guidance.
Thank you in advance!
Expected Behavior
It should be able to click on all remotes and load succesfully the remote with docker
GitHub Repo
No response
Steps to Reproduce
.
Nx Report
Your repository uses a higher version of Nx (20.3.1) than your global CLI version (19.4.4)
For more information, see https://nx.dev/more-concepts/global-nx
Failure Logs
fid_dev_front | [webpack-dev-server] [connect-history-api-fallback] Not rewriting GET /remoteEntry.mjs because the client does not accept HTML.
Also 404 Not Found on https://app-dev.fideliste.com:4201/remoteEntry.mjs
Package Manager Version
10.9.2
Operating System
macOS
Linux
Windows
Other (Please specify)
Additional Information
No response
The text was updated successfully, but these errors were encountered:
Current Behavior
Hi everyone,
I am working on a host project that loads five remote modules with Nx and Angular. After upgrading Nx to version 20.3.1 and Angular to version 19.0.7, everything builds successfully, and there are no build errors. However, when I attempt to access three of the remotes via their respective links, I encounter an issue where they do not load, whereas the other two remotes work fine.
Client-side Issue: When I click the link to load a remote, I receive a 404 Not Found error. Interestingly, if I manually click on the link in the browser, it works, and I can access the resource.
Verbose Log Output: When I run the command with --verbose, I see the following log entry:
2025-01-22 15:51:21 [webpack-dev-server] [connect-history-api-fallback] Not rewriting GET /remoteEntry.mjs because the client does not accept HTML.
Docker Setup: I am using Docker to build the project where the issue occurs. However, when I install the dependencies manually and start the project with the following script:
everything works as expected, and I can click and load all remotes successfully.
Here the configuration of one remote in admin/project.json:
in admin/module-federation.config.ts
in admin/webpack.config.ts
and then define the route like this:
I am aware that loadRemoteModule is deprecated, but I have not yet found a suitable replacement with the new API.
I also found a simular topic: #28479 but it seems it has been close due to the lack of activity.
I tried also load all the modules independantly, and also all without one (production) one and it seems it works too with docker. So it seems that production remote is the problem, but the configuration is the same are all others...
Any insights, suggestions, or questions are welcome. I am quite perplexed by this issue and would greatly appreciate any help or guidance.
Thank you in advance!
Expected Behavior
It should be able to click on all remotes and load succesfully the remote with docker
GitHub Repo
No response
Steps to Reproduce
.
Nx Report
Failure Logs
fid_dev_front | [webpack-dev-server] [connect-history-api-fallback] Not rewriting GET /remoteEntry.mjs because the client does not accept HTML. Also 404 Not Found on https://app-dev.fideliste.com:4201/remoteEntry.mjs
Package Manager Version
10.9.2
Operating System
Additional Information
No response
The text was updated successfully, but these errors were encountered: