Scope-based scaffolding
init creates the workspace; generate creates hosts, remotes, packages, libraries and a design system. Apps live at apps/
A CLI that scaffolds and synchronises Module Federation hosts and remotes, plus small runtime packages for loading and coordinating them. Pre-1.0.
npx mfe-forge@latest init my-platform --package-manager npm
cd my-platform
# set "workspaces": ["apps/*/*", "packages/*"] in package.json (see Installation)
npx mfe generate host platform/host
npx mfe generate app platform/dashboard
npm install
npx mfe doctorThe npm package is mfe-forge; it installs the binaries mfe-forge and mfe. The Quick start continues from here and renders the remote inside the host. Requirements are listed under Installation.
Status
MFE Forge is on the 0.x line and minor versions may break. Templates currently use @originjs/vite-plugin-federation with Vite 5.4; Module Federation 2.0 support is planned. See Status and maturity.
| Package | Description |
|---|---|
mfe-forge | CLI: init, generate, dev, build, test, sync, doctor, config and diagnostics |
@mfe-forge/core | MFErrorBoundary, LazyRemote, RemoteLoader, RemoteRegistry, EventBus |
@mfe-forge/router | useMFENavigation, useRouteSync, generateRoutes, createRouteGuard for React Router 7 |
@mfe-forge/store | useGlobalStore, createScopedStore, syncStoreAcrossMFEs for Zustand 5 |
@mfe-forge/design | Design tokens and applyTokens for CSS custom properties |
@mfe-forge/testing | renderMFE, mockRemoteModule, waitForRemoteLoad, Playwright e2eHelpers |
All six packages are released together under one version number.