NF-028: Remote component rendered in the browser only
The host did not render a remote component on the server. The server HTML has its fallback and the browser renders the component. The message names the...
Why This Error Occurred
The host did not render a remote component on the server. The server HTML has its fallback and the browser renders the component. The message names the case.
Possible Ways to Fix It
-
Unverified or untrusted build: sign the remote's descriptor (
NF_COMPONENTS_SIGNING_KEYat build time,publicKeysin the host) or pin its builds, and pass the descriptor fromgetComponentDescriptorunchanged:// federation.ts components: { ssr: { publicKeys: [/* the remote's public JWK */] } } -
Node.js too old: run the host on Node.js 20.16 or newer.
-
Nested remotes: expose the nested components from their own remote and use them from the host directly.
-
Mixed-router hosts: build remotes with a Module Federation plugin version the library lists.
-
Stale share cache: restart the dev server, or install one copy of each host-provided module.
-
To turn server rendering off without a warning, set
components.ssr: false.
Useful Links
NF-027: Remote component server code failed its integrity check
The host could not verify a remote component build, so it did not run its server code. The component renders in the browser only. Server rendering runs...
NF-029: Remote component failed to load
A remote component could not be loaded: its build descriptor could not be fetched or is invalid, or its module failed to load on the server or in the...