For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt, and this page is available as Markdown at /plugins/module-federation-plugin-v1.md.
close

ModuleFederationPluginV1

This plugin corresponds to Module Federation v1.0, which is the ModuleFederationPlugin in webpack.

Tip

Module Federation v1.0 is no longer being iterated. We recommend using Module Federation v1.5 or v2.0. See Module Federation.

Examples

rspack.config.mjs
import { rspack } from '@rspack/core';

export default {
  plugins: [
    new rspack.container.ModuleFederationPluginV1({
      name: 'host',
    }),
  ],
};

Options

  • Type:
interface ModuleFederationPluginV1Options {
  name: string;
  filename?: string;
  exposes?: Exposes;
  remotes?: Remotes;
  shared?: Shared;
  runtime?: EntryRuntime;
  shareScope?: ShareScope;
  remoteType?: ExternalsType;
  library?: LibraryOptions;
  enhanced?: boolean;
}

The name option is required. For details about the shared fields, see ModuleFederationPlugin options. Module Federation v1 does not support implementation, runtimePlugins, or shareStrategy.