Skip to content

Conversation

@ScriptedAlchemy
Copy link
Owner

Implements full Module Federation support for Rsbuild with host/remote examples and E2E tests.

This enables server-side rendering and client-side hydration of federated modules, with node chunks loading over HTTP, leveraging asyncStartup: true for efficient module loading. The Rsbuild plugin now conditionally adjusts Rspack output settings (target, chunkFormat, chunkLoading, library type) when Module Federation is detected to ensure compatibility with @module-federation/node.


Open in Cursor Open in Web

cursoragent and others added 3 commits February 10, 2026 20:38
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
@cursor
Copy link

cursor bot commented Feb 10, 2026

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@changeset-bot
Copy link

changeset-bot bot commented Feb 10, 2026

⚠️ No Changeset found

Latest commit: a290354

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
@ScriptedAlchemy ScriptedAlchemy changed the title Rsbuild module federation node feat(module-federation) :support module federation in tanstack start Feb 11, 2026
@ScriptedAlchemy ScriptedAlchemy marked this pull request as ready for review February 11, 2026 12:13
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 92a0c88327

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +487 to +491
module: false,
chunkFormat: 'commonjs',
chunkLoading: 'async-node',
library: {
type: 'commonjs-module',

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Load CommonJS SSR bundle with a CommonJS loader

When module federation is detected, this block forces the SSR output to CommonJS (output.module: false, library.type: 'commonjs-module'), but the production preview middleware in the same file still loads server.js via await import(pathToFileURL(...)). In "type": "module" apps (the default in the new examples), importing a CommonJS .js bundle as ESM fails at runtime (module is not defined/ESM interop error), so rsbuild preview will fail to serve requests for MF-enabled apps.

Useful? React with 👍 / 👎.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see this failure in pipeline too

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Although do not run into it in local

Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
@autofix-troubleshooter
Copy link

Hi! I'm the autofix logoautofix.ci troubleshooter bot.

It looks like you correctly set up a CI job that uses the autofix.ci GitHub Action, but the autofix.ci GitHub App has not been installed for this repository. This means that autofix.ci unfortunately does not have the permissions to fix this pull request. If you are the repository owner, please install the app and then restart the CI workflow! 😃

@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 12, 2026

More templates

@tanstack/arktype-adapter

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/arktype-adapter@6

@tanstack/eslint-plugin-router

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/eslint-plugin-router@6

@tanstack/history

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/history@6

@tanstack/nitro-v2-vite-plugin

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/nitro-v2-vite-plugin@6

@tanstack/react-router

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/react-router@6

@tanstack/react-router-devtools

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/react-router-devtools@6

@tanstack/react-router-ssr-query

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/react-router-ssr-query@6

@tanstack/react-start

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/react-start@6

@tanstack/react-start-client

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/react-start-client@6

@tanstack/react-start-server

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/react-start-server@6

@tanstack/router-cli

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-cli@6

@tanstack/router-core

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-core@6

@tanstack/router-devtools

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-devtools@6

@tanstack/router-devtools-core

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-devtools-core@6

@tanstack/router-generator

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-generator@6

@tanstack/router-plugin

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-plugin@6

@tanstack/router-ssr-query-core

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-ssr-query-core@6

@tanstack/router-utils

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-utils@6

@tanstack/router-vite-plugin

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/router-vite-plugin@6

@tanstack/solid-router

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/solid-router@6

@tanstack/solid-router-devtools

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/solid-router-devtools@6

@tanstack/solid-router-ssr-query

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/solid-router-ssr-query@6

@tanstack/solid-start

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/solid-start@6

@tanstack/solid-start-client

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/solid-start-client@6

@tanstack/solid-start-server

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/solid-start-server@6

@tanstack/start-client-core

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/start-client-core@6

@tanstack/start-fn-stubs

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/start-fn-stubs@6

@tanstack/start-plugin-core

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/start-plugin-core@6

@tanstack/start-server-core

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/start-server-core@6

@tanstack/start-static-server-functions

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/start-static-server-functions@6

@tanstack/start-storage-context

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/start-storage-context@6

@tanstack/valibot-adapter

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/valibot-adapter@6

@tanstack/virtual-file-routes

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/virtual-file-routes@6

@tanstack/vue-router

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/vue-router@6

@tanstack/vue-router-devtools

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/vue-router-devtools@6

@tanstack/vue-router-ssr-query

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/vue-router-ssr-query@6

@tanstack/vue-start

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/vue-start@6

@tanstack/vue-start-client

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/vue-start-client@6

@tanstack/vue-start-server

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/vue-start-server@6

@tanstack/zod-adapter

npm i https://pkg.pr.new/ScriptedAlchemy/router/@tanstack/zod-adapter@6

commit: a290354

cursoragent and others added 2 commits February 12, 2026 05:58
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants