[codex] add federation hmr parity controls to zephyr wrappers#354
Draft
ScriptedAlchemy wants to merge 2 commits intomainfrom
Draft
[codex] add federation hmr parity controls to zephyr wrappers#354ScriptedAlchemy wants to merge 2 commits intomainfrom
ScriptedAlchemy wants to merge 2 commits intomainfrom
Conversation
|
| Command | Status | Duration | Result |
|---|---|---|---|
nx affected -t build --skipRemoteCache |
❌ Failed | 41s | View ↗ |
nx affected -t test |
✅ Succeeded | 1m 46s | View ↗ |
nx affected -t lint |
✅ Succeeded | 9s | View ↗ |
nx affected --exclude=!libs/** -t build --skipR... |
✅ Succeeded | 13s | View ↗ |
☁️ Nx Cloud last updated this comment at 2026-02-11 11:57:18 UTC
|
View your CI Pipeline Execution ↗ for commit 20981f7
☁️ Nx Cloud last updated this comment at |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
This PR adds explicit Module Federation HMR parity controls to Zephyr's webpack/rspack/rsbuild plugin path and changes the default mutation behavior so local development remotes are no longer rewritten away from native dev/HMR flows.
Problem
In Zephyr-wrapped federated builds, local dev remotes could be rewritten to Zephyr delegate/runtime forms during config mutation. That behavior breaks the expected local Module Federation development experience where remote changes propagate through native HMR/Fast Refresh. DTS consume settings were also easy to miss in build/watch flows, especially when tools run with production env defaults while still watching.
Root Cause
Zephyr's remotes mutation pipeline did not have an HMR-aware mode. It always treated remotes uniformly and did not preserve local dev endpoints. There was also no central place to normalize dev/watch behavior and apply DTS consume-type defaults for HMR-compatible development.
What Changed
zephyr-xpack-internal:ZephyrFederationHmrOptionsnormalizeFederationHmrOptionsisLocalDevRemoteshouldPreserveLocalDevRemotesapplyFederationDtsOptionsmutWebpackFederatedRemotesConfignow acceptsoptions.federationHmr.zephyr-webpack-pluginzephyr-rspack-pluginzephyr-rsbuild-pluginzephyr-xpack-internal.Behavioral Effect for Users
federationHmroptions.Validation
Executed in
zephyr-packages:pnpm nx run-many -t build --projects=zephyr-xpack-internal,zephyr-webpack-plugin,zephyr-rspack-plugin,zephyr-rsbuild-plugin --skip-nx-cachepnpm nx run-many -t lint --projects=zephyr-xpack-internal,zephyr-webpack-plugin,zephyr-rspack-plugin,zephyr-rsbuild-plugin --skip-nx-cache