Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

In Native Federation, federation.config.js describes a remote’s identity, exposed modules and shared dependencies; a bundler adapter connects that configuration to the application build, and the federation builder then writes artifacts including remoteEntry.json. The host fetches that JSON at runtime to resolve and load exposed modules. The sequence below follows the documented Core v3 lifecycle; the current core repository identifies itself as v4, so verify version-sensitive options against your installed packages.

What the configuration describes

A Native Federation configuration defines what a remote offers and how it participates in dependency sharing. Its central pieces are a name, an exposes map, and shared-dependency settings. An expose maps a public key—such as ./component—to a source file. The configuration can also include internal shared mappings, packages to skip, additional externals and feature options. The Core v3 configuration reference documents sharing through share or shareAll; check the specific adapter and package major version before copying option names or defaults. Native Federation Core v3 configuration reference.

The current core repository README identifies the project as v4 and demonstrates the configuration-to-builder flow, including an esbuild adapter example. The detailed lifecycle and artifact behavior below comes from documentation labeled Core v3, and may differ in later releases. Native Federation core repository README.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

How the build moves from config to artifacts

1. Initialize the federation builder

The integration gives the builder its workspace context and configuration, including values such as workspaceRoot, outputPath, tsConfig and federationConfig. The builder resolves the config path from its workspace options. The exact option surface depends on the project’s core and adapter versions.

2. Run the application bundler with federation externals

Native Federation Core is described as framework- and bundler-agnostic; an adapter supplies bundler-specific behavior. The documented esbuild example runs the application bundler with federationBuilder.externals. Keeping those packages external prevents the application bundle from inlining dependencies intended to resolve through federation’s import map.

3. Build the federation outputs

After the application bundler completes, call federationBuilder.build(). The documented integration contract is ordered: initialize the builder, run the app bundler while preserving its federation externals, then build federation artifacts. The repository README’s builder example shows this sequence.

The Core v3 build-process documentation describes three phases: bundling exposed modules and shared mappings; bundling shared packages; and writing federation metadata and an import map. Its wording is: “The exposed descriptions and the shared descriptions are assembled into a FederationInfo and written as remoteEntry.json; the shared list alone is also written as importmap.json.” Native Federation Core v3 Build Process.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

That v3 page also describes browser/node groupings and default or separate shared-package groupings. Production output filenames may be hashed, while development names are stable. These are version-specific implementation details, not guarantees for every adapter or release.

Build caching in the documented v3 lifecycle

The v3 build-process page documents a shared-package cache in node_modules/.cache/native-federation/<project>/. Its metadata includes a checksum of shared keys and versions plus the development flag. Unchanged groups can be reused; changes invalidate and rebuild affected groups. Some watch-mode integrations can skip shared bundling on later rebuilds when shared packages have not changed. Treat this as an optimization described for that lifecycle, not a universal adapter guarantee.

What remoteEntry.json contains

The Core v3 artifact reference describes remoteEntry.json as federation metadata with name, exposes and shared fields. A development build may also include buildNotificationsEndpoint when notifications are enabled. Native Federation Core v3 Build Artifacts.

  • Exposes: public module keys and the emitted file for each exposed module.
  • Shared packages: package name and output file, with version-related details such as required and concrete versions, plus singleton and strict-version behavior where applicable.

The host or runtime can construct each asset URL by resolving the output filename relative to the directory containing the fetched entry. That lets the entry describe files without requiring the host to hard-code each emitted filename.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The companion importmap.json is a simpler package-name-to-output-file mapping derived from the shared list. The v3 artifact reference says the Native Federation runtime builds its import map from remoteEntry.json; the companion file is available to tooling or host integrations that need the flatter mapping.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

How the host consumes the entry

A host is the application that loads remotes. A deployment manifest can map remote names to their remoteEntry.json URLs, keeping environment-specific locations separate from application code. Native Federation terminology reference.

The Core v3 getting-started guide demonstrates loading a manifest through initFederation, then requesting an exposed module with loadRemoteModule. The runtime uses the entry metadata to assemble import-map resolutions and load the module. Native Federation Core v3 Getting Started.

Initialization order matters: the guide calls out es-module-shims and a bootstrap split so code that touches shared dependencies does not run before initFederation resolves. Put shared-dependency-dependent startup behind that initialization rather than allowing the application’s normal entry code to execute first.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Do not confuse the JSON entry with Webpack’s container entry

Native Federation’s remoteEntry.json is metadata consumed by its runtime; it is not Webpack’s familiar JavaScript container. Webpack’s ModuleFederationPlugin conventionally emits a remoteEntry.js container, a distinct implementation with its own loading model. Webpack ModuleFederationPlugin documentation.

The Native Federation core repository currently identifies itself as v4, while the detailed build-process, artifact, configuration and getting-started references here are under the Core v3 documentation path. Confirm exact options, output details and adapter behavior against the versions installed in your project before treating a v3 example as copy-and-paste configuration.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.