feat(core): enable Rspack runtime mode by default - #1806
Conversation
Known issues and cold-cache verificationRetested from fresh source archives after clearing all local Rspack filesystem caches and generated integration outputs, using:
1. Missing
|
| Format | Raw delta | Gzip delta |
|---|---|---|
| ESM | +124 B | +570 B |
| CJS | +15,499 B | +9,331 B |
| UMD | +532 B | +233 B |
| MF | +20,557 B | +3,368 B |
| Other JS | +8,575 B | +1,042 B |
| Total | +45,287 B | +14,544 B |
Other JS is included explicitly so that the format rows sum to the reported total.
Current integration-test status
The cold rspack-mode run executes 83 test files / 323 tests:
- 321 passed
- 1 failed
- 1 todo
The only integration execution failure is the missing compatGetDefaultExport import described above.
Running webpack mode against the current PR expectations produces:
- 297 passed
- 25 failed
- 1 todo
All 25 failures are snapshot or generated-string assertion mismatches because this branch has updated those expectations to the rspack-mode representation; they are not webpack-runtime execution failures.
Additional compiler and output correctness regressions that are not covered by the current Rslib integration suite are documented in the follow-up comment.
Given the confirmed integration failure and the additional minimal correctness regressions, this should remain a draft and runtimeMode: 'rspack' should not become the default until those issues are fixed.
Additional output optimization: redundant
|
Additional Rspack 2.1.6 blockersA second audit found three more correctness regressions in the new {
mode: 'none',
target: 'node',
entry: './src/index.js',
experiments: { runtimeMode: 'rspack' },
output: {
path: path.resolve(__dirname, 'dist'),
filename: 'index.mjs',
module: true,
chunkFormat: false,
chunkLoading: 'import',
library: { type: 'modern-module' },
},
}The common version/mode matrix is:
These regressions start with web-infra-dev/rspack#14741 / merge commit 1. Exported function named
|
Non-blocking output follow-upA cold-cache AST scan found redundant top-level runtime invocations emitted as For this count, “top-level runtime wrapper” is defined precisely as:
Using that definition:
Thirteen additional renderer IIFEs occur inside UMD/MF library shells; they are intentionally excluded from the top-level count above. Conservatively replacing |
Canary cold-revalidation updateThis supersedes the current-status conclusions in the earlier Rspack 2.1.6 comments; those comments remain useful as version-specific history. I removed all local Current validation status:
The five integration failures are stale generated-string expectations for improvements made by this canary: the duplicate public-path declaration, dead SVGR bootstrap, and three long The canary also fixes the previously reported missing The remaining issues are below. Scope note: issues 1 and 2 are not current Rslib integration execution failures. They require specific input binding names under 1. A specific exported
|
a7033e6 to
9074f9c
Compare
Summary
@rspack/coreglobally with@rspack-canary/core@2.1.8-canary-4b189917-20260802173728.experiments.runtimeMode: 'rspack'by default while preserving user overrides.Related Links
Checklist