-
Notifications
You must be signed in to change notification settings - Fork 0
feat(module-federation) :support module federation in tanstack start #6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: feat/rsbuild
Are you sure you want to change the base?
feat(module-federation) :support module federation in tanstack start #6
Conversation
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 Agent can help with this pull request. Just |
|
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
There was a problem hiding this 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".
| module: false, | ||
| chunkFormat: 'commonjs', | ||
| chunkLoading: 'async-node', | ||
| library: { | ||
| type: 'commonjs-module', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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 👍 / 👎.
There was a problem hiding this comment.
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
There was a problem hiding this comment.
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>
|
Hi! I'm the 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! 😃 |
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
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: truefor 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.