# rspack: what changed from 1 to 2 - Product: rspack (https://whatsnew.fyi/product/rspack) - Vendor: rspack - Range: changelog entries numbered after v1.7.12 up to and including v2.2.2, stable releases only - Entries below: 15 releases (newest first) - Resolved: 1 is v1.7.12 and 2 is v2.2.2, the newest stable release of each major we track - Carrying security changes: 0 · CVEs mentioned: 0 · Mentioning breaking changes: 0 · Removing or deprecating something: 2 - Page: https://whatsnew.fyi/product/rspack/compare/1...2 What's New is an index, not a publisher: every entry below links to the vendor's own release notes, which are the authoritative source. Entries are labelled where they are hand-curated sample data, pre-releases, or drawn from a secondary source such as a developer blog. Reuse: the summaries, labels and curation here are © What's New. Quote freely with attribution and a link back; wholesale republication of the corpus is not permitted — terms: https://whatsnew.fyi/terms. The vendors' own release notes remain their publishers'. ## What changed (199 changes, grouped by kind) ### Added #### v2.2.2 (2026-09-01) - Add infrastructure logging to the new cache - Add JavascriptModulesPlugin.getChunkFilenameTemplate #### v2.2.1 (2026-08-27) - Align wasmStreamingFallback with webpack - Track dependencies in loader cache #### v2.2.0 (2026-08-26) - Implement generation-based memory cache eviction - Add idle cache compaction with interruption handling - Integrate module code generation to the new cache - Add fine-grained new cache options - Add compat-hashed module ids - Analyze dynamic imports in Promise.all destructuring - Integrate new cache into source map devtool plugin - Add compilation.runtimeTemplate - Add compact chunk ids - Support opt-in per-loader caching #### v2.1.10 (2026-08-13) - Expose ExternalModule chunkCondition hook - Implement new cache system - Integrate new cache to minimize cache #### v2.1.9 (2026-08-11) - Warn on unknown import.meta properties - Add builds for binding-linux-(ppc64,s390x)-gnu - Support --no-git flag in create-rspack - Support caseSensitive option in import.meta.glob #### v2.1.8 (2026-08-04) - Support cache.name and cache.storage.location options to align with webpack's persistent cache semantics - Emit css.c and css.r in the hot-update manifest for precise CSS updates - Inject module origin for import.meta.rstest #### v2.1.6 (2026-07-28) - Support import.meta.env #### v2.1.4 (2026-07-14) - Support fine-grained import.meta parser options allowing each known import.meta property to be configured independently - Support static worker new URL output with module.parser.javascript.worker accepting an object form with alias and url - Support logical assignment for chunk loading global in runtime #### v2.1.3 (2026-07-07) - Add name/value accessors to ESMExportSpecifierDependency - Expose the real Chunk instance to filename functions #### v2.1.2 (2026-06-30) - Support `import.meta` style module variables including `import.meta.rspackPublicPath`, `import.meta.rspackBaseUri`, `import.meta.rspackShareScopes`, `import.meta.rspackInitSharing`, `import.meta.rspackNonce`, `import.meta.rspackUniqueId`, `import.meta.rspackVersion`, and `import.meta.rspackHash` #### v2.1.1 (2026-06-27) - Add dependencyId and loc to export usage edges in rsdoctor #### v2.1.0 (2026-06-26) - Expose module error JS API (also in v2.1.0-beta.0) - Log persistent cache read and write timings (also in v2.1.0-beta.0) - Expose getProvidedExports() to JS API (also in v2.1.0-beta.0) - Support drop inactive branch dependencies for member expressions - Introduce experimental.runtimeMode (also in v2.1.0-beta.0) - Support branch guarded export presence for `in` on ESM imports - Bump swc to support react compiler - Expose export usage graph to rsdoctor - Add maxAge and maxGenerations for persistent cache cleanup (also in v2.1.0-beta.0) - Support riscv64 targets #### v2.1.0-beta.0 (2026-06-18) - Support React Compiler in builtin:swc-loader - Support drop inactive branch dependencies for member expr - Support branch guarded export presence for in on ESM imports ### Changed #### v2.2.2 (2026-09-01) - Optimize deterministic module id assignment - Share runtimes in flag dependency usage - Optimize module rendering for chunk assets - Optimize create module hashes #### v2.2.1 (2026-08-27) - Store FactorizeInfo path dependencies as compact slices #### v2.2.0 (2026-08-26) - Improve unicode handling and support more CSS modules cases, boost performance - Cache converted module original source - Batch splitChunks JavaScript callbacks - Avoid parsing concatenated module codegen - Preallocate identifier path buffers - Intern ArcPath as a single-allocation prehashed path - Use rayon parallel scheduling for new cache db - Skip the directory walk for glob patterns without metacharacters #### v2.1.9 (2026-08-11) - Cache and order static patterns in copy-plugin - Limit incremental HMR asset processing - Avoid unnecessary call wrappers for runtime helpers - Cache compilation assets proxy - Avoid copying aligned archive buffers in cache - Avoid duplicating export dependency data in JSON - Improve source map convert performance #### v2.1.8 (2026-08-04) - cache.storage.directory is now the base directory, with final cache location defaulting to / #### v2.1.7 (2026-07-29) - Share source code across diagnostics to improve performance #### v2.1.6 (2026-07-28) - Cache module concatenation analysis across roots - Reuse module concatenation search state - Reduce module concatenation hot-path overhead #### v2.1.4 (2026-07-14) - Enable parallel wasmtime compilation for improved performance - Optimize ESM linking passes - Deduplicate repeated dynamic reexport code - Reduce hook macro expansion size and optimize performance #### v2.1.3 (2026-07-07) - Erase js tap storage types to reduce binary size - Build rspack source maps directly - Optimize module hash creation - Pre-size per-module maps and vecs in mangle_exports #### v2.1.2 (2026-06-30) - Deduplicate runtime module macro glue for improved performance - Avoid cloning side effects artifact in module concatenation #### v2.1.1 (2026-06-27) - Add persistent cache for SourceMapDevToolPlugin #### v2.1.0 (2026-06-26) - Enable pureFunctions by default - Make persistent cache max generations default to 3 - Rename persistent cache maxGenerations to maxVersions - Harden persistent cache version cleanup with typed version - Make stale version cleanup fire-and-forget #### v2.1.0-beta.0 (2026-06-18) - Enable side-effect-free function analysis by default in production builds - Bump swc to support react compiler ### Fixed #### v2.2.2 (2026-09-01) - Generate correct prefetch child assets - Keep import.meta.url in createRequire when importMeta is disabled - Align module need_build and FileSystemInfo with webpack - Support all EnvironmentPlugin default values - Improve incremental chunk graph reuse - Await patch delivery before sealing completes in rsdoctor - Ignore exportsOnly in local ident hashes for CSS - Fallback eval devtools for modern-module - Report diagnostics for unsupported context modes #### v2.2.1 (2026-08-27) - Correct compact hashed module and chunk IDs naming from compat-hashed to compact-hashed, with deprecated compatibility aliases maintained for backward compatibility - Disable stats logging by default - Disable incremental outside development mode - Run afterCompile before shouldEmit and asset emission - Clear stale issuer updates between rebuilds - Exclude asset output path from URLs in CSS - Bound concurrent asset writes during emit - Update swc_ecma_minifier to 61.0.4 - Store server compiler ID in native coordinator - Persist dependency id in metadata - Normalize restored paths on Windows #### v2.2.0 (2026-08-26) - Pass HMR error to Preact refresh recovery handler - Strip BOM from module content before concatenation in CSS extraction #### v2.1.10 (2026-08-13) - Process remaining module copies at lower priorities in split-chunks - Allow scope hoisting for new URL targets in new-url-relative mode in esm_library - Bump rkyv to 0.8.18 to fix RUSTSEC-2026-0233, RUSTSEC-2026-0234, and RUSTSEC-2026-0235 - Normalize string context from loaded config in CLI - Share ExternalModule hooks across core instances - Fix new cache compile failure on 32-bit platforms #### v2.1.9 (2026-08-11) - Improve circular real content hash error diagnostics - Keep compilation dependency iterators disjoint - Align cache version semantics with webpack - Preserve ignored URL when import.meta.url is disabled - Avoid runtime lock deadlock in napi - Match compiler prefixes exactly in lazy compilation - Avoid injecting shared providers into worker entrypoints in Module Federation - Handle optional chains in member hook traversal - Support loader context APIs in parallel loaders #### v2.1.8 (2026-08-04) - Preserve entry dependency identity in binding - Preserve Lightning CSS license comments in loader - Add missing CJS interop runtime requirement for ESM - Avoid dead require bootstrap in runtime - Preserve collision-free createRequire imports in runtime - Clean up compilation-scoped plugin caches - Hoist test API imports by source order in rstest - Release custom runtime module generators on close in binding - Preserve context exports in rspack runtime mode - Correct full-hash chunk filenames in runtime - Use POSIX asset keys in copy-plugin - Remove redundant runtime declarations - Handle SharedWorker string name option - Avoid runtime scope conflicts in module factories - Preserve direct exports bindings #### v2.1.7 (2026-07-29) - Release module graph connection wrappers #### v2.1.6 (2026-07-28) - Materialize namespace object for concatenated modules - Parse preserved createRequire arguments - Invalidate module hashes when assigning deterministic and natural ids - Disable incremental chunk assets for entry fullhash filenames - Propagate asset emit errors - Avoid JavaScript output for URL-only assets - Avoid worker external facade in bundleless output - Execute worker entry modules in modern-module output - Preserve defineConfig inference in CLI - Preserve structured swc diagnostics in swc-loader - Respect DllPlugin context for concatenated modules - Scope maxVersions by compiler using compilerPath in cache #### v2.1.5 (2026-07-21) - Respect runtime mode in mf identifiers - Preserve multiple referenced client exports in rsc - Preserve createRequire().resolve with literal import.meta.url when requireResolve is disabled - Preserve inline match resource imports in css - Short-circuit optional import.meta calls - Preserve exports for dynamic client references in rsc - Avoid live chunk access when serializing stale stats - Register hoisted mocks before importActual imports in rstest - Run FsWatcher on a single owner task to fix concurrent &mut races - Add module type when options are omitted in module output for worker - Include output path in chunk render cache keys - Support real content hash update hooks #### v2.1.4 (2026-07-14) - Clean up runtime global rendering - Clean up chunk wrappers when compiler is garbage collected - Enable runtime mode ESM context imports - Revert Module Federation runtime identifiers - Include paths in native filesystem errors - Respect RSPACK_BINDING in loader workers - Invalidate the target compiler for lazy compilation #### v2.1.3 (2026-07-07) - Update runtime context during hot updates - Inline-value check must precede deferred pure checks in concatenation - Skip re-applying unchanged CSS during HMR - Preserve asset bytes for binary files - Dedupe link HMR stylesheets in CSS - Emit manifest assets with forward-slash names on Windows - Unwrap dynamic source-phase imports in modern-module output - Preserve static source-phase external bindings in esm_library - Distinguish css wrapper sourcemap names - Keep path data chunk compatible in binding #### v2.1.2 (2026-06-30) - Inject runtime require into browser MF runtime - Preserve import phase in dynamic import external rendering - Empty references export for cjs and dynamic import tree shaking #### v2.1.1 (2026-06-27) - Add guard for link.parentNode in css runtime - Revert cjs export assignment side effects optimization #### v2.1.0 (2026-06-26) - Preserve inline source content for transform sourcemaps (also in v2.1.0-beta.0) - Remove webpackSource and webpackDefer magic comments (also in v2.1.0-beta.0) - Apply global overrideStrict for ContextModule (also in v2.1.0-beta.0) - Filter ignored-subtree events that emit a spurious folder change in watcher - Handle nested pure function calls in tree-shaking (also in v2.1.0-beta.0) #### v2.1.0-beta.0 (2026-06-18) - Filter ignored-subtree events that emit a spurious folder change - Use ChunkWithSizeInfo delimiter in maxInitialSize chunk naming fallback path - Wait for in-flight build before closing compiler - Point wasi-worker-browser export to dist file - Cache import.meta filename and dirname outside eval ### Removed #### v2.1.10 (2026-08-13) - Remove noisy import.meta warnings for unknown properties #### v2.1.7 (2026-07-29) - Remove the import.meta.env experimental feature that was introduced in Rspack 2.1.6 ## Release notes ### v2.2.2 - Date: 2026-09-01 - Version: v2.2.2 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.2.2 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.2.2 - **added** — Add infrastructure logging to the new cache - **added** — Add JavascriptModulesPlugin.getChunkFilenameTemplate - **changed** — Optimize deterministic module id assignment - **changed** — Share runtimes in flag dependency usage - **changed** — Optimize module rendering for chunk assets - **changed** — Optimize create module hashes - **fixed** — Generate correct prefetch child assets - **fixed** — Keep import.meta.url in createRequire when importMeta is disabled - **fixed** — Align module need_build and FileSystemInfo with webpack - **fixed** — Support all EnvironmentPlugin default values - **fixed** — Improve incremental chunk graph reuse - **fixed** — Await patch delivery before sealing completes in rsdoctor - **fixed** — Ignore exportsOnly in local ident hashes for CSS - **fixed** — Fallback eval devtools for modern-module - **fixed** — Report diagnostics for unsupported context modes ##### What's Changed ###### New Features 🎉 * feat(cache): add intrastructure logging to the new cache by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15338 * feat(javascript): add JavascriptModulesPlugin.getChunkFilenameTemplate by @kakiuwang-ui in https://github.com/web-infra-dev/rspack/pull/15280 ###### Performance 🚀 * perf(ids): optimize deterministic module id assignment by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15393 * perf: share runtimes in flag dependency usage by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15388 * perf(core): optimize module rendering for chunk assets by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15394 * perf(core): optimize create module hashes by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15396 ###### Bug Fixes 🐞 * fix(stats): generate correct prefetch child assets by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15208 * fix: keep import.meta.url in createRequire when importMeta is disabled by @lazerg in https://github.com/web-infra-dev/rspack/pull/15273 * fix(core): align module need_build and FileSystemInfo with webpack by @hardfist in https://github.com/web-infra-dev/rspack/pull/15374 * fix(types): support all EnvironmentPlugin default values by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15382 * fix: improve incremental chunk graph reuse by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15373 * fix(rsdoctor): await patch delivery before sealing completes by @kakiuwang-ui in https://github.com/web-infra-dev/rspack/pull/15399 * fix(css): ignore exportsOnly in local ident hashes by @mattcosta7 in https://github.com/web-infra-dev/rspack/pull/15364 * fix: fallback eval devtools for modern-module by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/15404 * fix: report diagnostics for unsupported context modes by @dr4gan0x in https://github.com/web-infra-dev/rspack/pull/15361 ###### Refactor 🔨 * refactor(loader): reuse filesystem snapshots for cache dependencies by @intellild in https://github.com/web-infra-dev/rspack/pull/15366 * refactor(core): remove BuildInfo clone by @hardfist in https://github.com/web-infra-dev/rspack/pull/15377 ###### Document 📖 * docs: correct compact hashed API names by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15358 * docs: improve built-in plugin overview and examples by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15354 * docs: move webpack attribution to page footer by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15365 * docs: improve low-level plugin documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15368 * docs: update webpack plugin compatibility by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15369 * docs: remove version info before Rspack 1.3.0 by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15371 * docs: standardize plugin documentation structure by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15378 * docs: improve BannerPlugin option documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15392 * docs: improve IgnorePlugin documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15395 * docs: improve plugin option documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15398 * docs: remove extra code block spacing in collapse panels by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15403 * docs: improve ContextReplacementPlugin documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15410 * docs: improve CssExtractRspackPlugin documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15411 * docs: improve HtmlRspackPlugin documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15412 * docs: improve HTML plugin guidance by @chenjiahan i _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.2.2]_ ### v2.2.1 - Date: 2026-08-27 - Version: v2.2.1 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.2.1 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.2.1 - **fixed** — Correct compact hashed module and chunk IDs naming from compat-hashed to compact-hashed, with deprecated compatibility aliases maintained for backward compatibility - **added** — Align wasmStreamingFallback with webpack - **added** — Track dependencies in loader cache - **changed** — Store FactorizeInfo path dependencies as compact slices - **fixed** — Disable stats logging by default - **fixed** — Disable incremental outside development mode - **fixed** — Run afterCompile before shouldEmit and asset emission - **fixed** — Clear stale issuer updates between rebuilds - **fixed** — Exclude asset output path from URLs in CSS - **fixed** — Bound concurrent asset writes during emit - **fixed** — Update swc_ecma_minifier to 61.0.4 - **fixed** — Store server compiler ID in native coordinator - **fixed** — Persist dependency id in metadata - **fixed** — Normalize restored paths on Windows ##### Highlights ###### Corrected `compact-hashed` IDs naming Rspack 2.2.0 introduced compact hashed module and chunk IDs under the mistakenly named `compat-hashed` option and `CompatHashedModuleIdsPlugin` / `CompatHashedChunkIdsPlugin` APIs. Rspack 2.2.1 corrects these names to `compact-hashed`, `CompactHashedModuleIdsPlugin`, and `CompactHashedChunkIdsPlugin`. The names introduced in 2.2.0 remain available as deprecated compatibility aliases, but we recommend upgrading to Rspack 2.2.1 and using the corrected names: ```js module.exports = { optimization: { moduleIds: 'compact-hashed', chunkIds: 'compact-hashed', }, }; ``` ##### What's Changed ###### New Features 🎉 * feat(wasm): align wasmStreamingFallback with webpack by @CoderSerio in https://github.com/web-infra-dev/rspack/pull/15334 * feat: track dependencies in loader cache by @intellild in https://github.com/web-infra-dev/rspack/pull/15325 ###### Performance 🚀 * perf(core): store FactorizeInfo path dependencies as compact slices by @stormslowly in https://github.com/web-infra-dev/rspack/pull/15306 ###### Bug Fixes 🐞 * fix(cli): disable stats logging by default by @hardfist in https://github.com/web-infra-dev/rspack/pull/15328 * fix: disable incremental outside development mode by @hardfist in https://github.com/web-infra-dev/rspack/pull/15332 * fix(core): run afterCompile before shouldEmit and asset emission by @kakiuwang-ui in https://github.com/web-infra-dev/rspack/pull/15326 * fix(cache): clear stale issuer updates between rebuilds by @zhsama in https://github.com/web-infra-dev/rspack/pull/15276 * fix(css): exclude asset output path from URLs by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15315 * fix(core): bound concurrent asset writes during emit by @lazerg in https://github.com/web-infra-dev/rspack/pull/15342 * fix(minify): update swc_ecma_minifier to 61.0.4 by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15343 * fix(ids): correct compact hashed API names by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15356 * fix(rsc): store server compiler ID in native coordinator by @SyMind in https://github.com/web-infra-dev/rspack/pull/15307 * fix(cache): persist dependency id in metadata by @hardfist in https://github.com/web-infra-dev/rspack/pull/15345 * fix(cache): normalize restored paths on Windows by @hardfist in https://github.com/web-infra-dev/rspack/pull/15357 ###### Refactor 🔨 * refactor(split-chunks): skip disjoint group cleanup by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15318 ###### Document 📖 * docs: 2.2.0 release blog by @stormslowly in https://github.com/web-infra-dev/rspack/pull/15240 * docs: clarify incremental mode requirement by @hardfist in https://github.com/web-infra-dev/rspack/pull/15339 * docs: move LLMs UI to page outline by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15341 * docs: reorganize plugin documentation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15347 ###### Other Changes * chore(deps): migrate to @rstackjs/doc-ui v1.14.9 by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15349 ##### New Contributors * @CoderSerio made their first contribution in https://github.com/web-infra-dev/rspack/pull/15334 **Full Changelog**: https://github.com/web-infra-dev/rspack/compare/v2.2.0...v2.2.1 ### v2.2.0 - Date: 2026-08-26 - Version: v2.2.0 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.2.0 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.2.0 - **added** — Implement generation-based memory cache eviction - **added** — Add idle cache compaction with interruption handling - **changed** — Improve unicode handling and support more CSS modules cases, boost performance - **added** — Integrate module code generation to the new cache - **added** — Add fine-grained new cache options - **added** — Add compat-hashed module ids - **added** — Analyze dynamic imports in Promise.all destructuring - **added** — Integrate new cache into source map devtool plugin - **added** — Add compilation.runtimeTemplate - **added** — Add compact chunk ids - **added** — Support opt-in per-loader caching - **changed** — Cache converted module original source - **changed** — Batch splitChunks JavaScript callbacks - **changed** — Avoid parsing concatenated module codegen - **changed** — Preallocate identifier path buffers - **changed** — Intern ArcPath as a single-allocation prehashed path - **changed** — Use rayon parallel scheduling for new cache db - **changed** — Skip the directory walk for glob patterns without metacharacters - **fixed** — Pass HMR error to Preact refresh recovery handler - **fixed** — Strip BOM from module content before concatenation in CSS extraction ##### What's Changed ##### 🎉 See [Announcing Rspack 2.2](https://rspack.rs/blog/announcing-2-2) for more details. ###### New Features 🎉 * feat: implement generation-based memory cache eviction by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15181 * feat: add idle cache compaction with interruption handling by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15182 * feat(css): improve unicode handling and support more css modules cases, boost performance by @intellild in https://github.com/web-infra-dev/rspack/pull/14809 * feat: integrate module code generation to the new cache by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15194 * feat(cache): add fine-grained new cache options by @hardfist in https://github.com/web-infra-dev/rspack/pull/15261 * feat(ids): add compat-hashed module ids by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14926 * feat: analyze dynamic imports in Promise.all destructuring by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/15249 * feat: integrate new cache into source map devtool plugin by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15269 * feat(core): add compilation.runtimeTemplate by @kakiuwang-ui in https://github.com/web-infra-dev/rspack/pull/15305 * feat(ids): add compact chunk ids by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14959 * feat(loader): support opt-in per-loader caching by @intellild in https://github.com/web-infra-dev/rspack/pull/15236 ###### Performance 🚀 * perf(binding): cache converted module original source by @SyMind in https://github.com/web-infra-dev/rspack/pull/15174 * perf: batch splitChunks JavaScript callbacks by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/15147 * perf(binding): exclude test loaders from release builds by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15209 * perf(binding): exclude perfetto from release WASI builds by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15221 * perf(binding): align release WASI optimizations by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15227 * perf(binding): optimize React Compiler crates for size by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15230 * perf: avoid parsing concatenated module codegen by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14852 * perf: preallocate identifier path buffers by @intellild in https://github.com/web-infra-dev/rspack/pull/15220 * perf(paths): intern ArcPath as a single-allocation prehashed path by @stormslowly in https://github.com/web-infra-dev/rspack/pull/15205 * perf: use rayon parallel scheduling for new cache db by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15251 * perf(core): skip the directory walk for glob patterns without metacharacters by @lazerg in https://github.com/web-infra-dev/rspack/pull/15297 * perf(split-chunks): skip single-chunk used exports grouping by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15312 * perf(core): precompile filename templates cache by @intellild in https://github.com/web-infra-dev/rspack/pull/15195 ###### Bug Fixes 🐞 * fix: pass HMR error to Preact refresh recovery handler by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15179 * fix(cache): limit shutdown compaction to a single pass by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15188 * fix(types): add missing stats fields by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15206 * fix(css-extract): strip BOM from module content before concatenation by @doxxx93 in https://github.com/web-infra-dev/rspack/pull/15169 * fix(core): decouple incremental artifacts from cache! by @hardfist in https://github.com/web-infra-dev/rspack/pull/15229 * fix(asset): preserve ESM imports in module output for "preserve" importMode by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/15165 * fix(css): CSS module dashed identifier a _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.2.0]_ ### v2.1.10 - Date: 2026-08-13 - Version: v2.1.10 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.10 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.10 - **removed** — Remove noisy import.meta warnings for unknown properties - **added** — Expose ExternalModule chunkCondition hook - **added** — Implement new cache system - **added** — Integrate new cache to minimize cache - **fixed** — Process remaining module copies at lower priorities in split-chunks - **fixed** — Allow scope hoisting for new URL targets in new-url-relative mode in esm_library - **fixed** — Bump rkyv to 0.8.18 to fix RUSTSEC-2026-0233, RUSTSEC-2026-0234, and RUSTSEC-2026-0235 - **fixed** — Normalize string context from loaded config in CLI - **fixed** — Share ExternalModule hooks across core instances - **fixed** — Fix new cache compile failure on 32-bit platforms > [!NOTE] > **Removed noisy `import.meta` warnings** > > Rspack 2.1.9 introduced warnings for unknown `import.meta` properties. Because they proved overly noisy in real-world builds, Rspack 2.1.10 removes them to reduce unnecessary diagnostics for custom or runtime-specific extensions. See #15166 for detail. ##### What's Changed ###### New Features 🎉 * feat: expose ExternalModule chunkCondition hook by @intellild in https://github.com/web-infra-dev/rspack/pull/15093 * feat: new cache system by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15110 * feat: integrate new cache to minimize cache by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15150 ###### Bug Fixes 🐞 * fix(split-chunks): process remaining module copies at lower priorities by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/15079 * fix(esm_library): allow scope hoisting for `new URL` targets in new-url-relative mode by @elecmonkey in https://github.com/web-infra-dev/rspack/pull/15155 * fix(deps): bump rkyv to 0.8.18 (fixes RUSTSEC-2026-0233/0234/0235) by @jesses-canva in https://github.com/web-infra-dev/rspack/pull/15156 * fix(cli): normalize string `context` from loaded config by @stormslowly in https://github.com/web-infra-dev/rspack/pull/15162 * fix: share ExternalModule hooks across core instances by @intellild in https://github.com/web-infra-dev/rspack/pull/15163 * fix: new cache compile failed on 32-bit platforms by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/15175 ###### Refactor 🔨 * refactor: migrate rspack_dojang into monorepo by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15124 ###### Document 📖 * docs: document Baseline queries by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15167 * docs: document __webpack_layer__ by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15170 ###### Other Changes * chore: clean up CODEOWNERS by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15159 * chore(deps): update rstack to v0.5.1 by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15160 * test: add CSS benchmarks by @intellild in https://github.com/web-infra-dev/rspack/pull/15106 * revert: unknown import.meta property warnings by @intellild in https://github.com/web-infra-dev/rspack/pull/15166 * test: add Baseline query coverage by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15168 * chore(ci): drop binary size limit from required check by @stormslowly in https://github.com/web-infra-dev/rspack/pull/15171 ##### New Contributors * @jesses-canva made their first contribution in https://github.com/web-infra-dev/rspack/pull/15156 **Full Changelog**: https://github.com/web-infra-dev/rspack/compare/v2.1.9...v2.1.10 ### v2.1.9 - Date: 2026-08-11 - Version: v2.1.9 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.9 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.9 - **added** — Warn on unknown import.meta properties - **added** — Add builds for binding-linux-(ppc64,s390x)-gnu - **added** — Support --no-git flag in create-rspack - **added** — Support caseSensitive option in import.meta.glob - **changed** — Cache and order static patterns in copy-plugin - **changed** — Limit incremental HMR asset processing - **changed** — Avoid unnecessary call wrappers for runtime helpers - **changed** — Cache compilation assets proxy - **changed** — Avoid copying aligned archive buffers in cache - **changed** — Avoid duplicating export dependency data in JSON - **changed** — Improve source map convert performance - **fixed** — Improve circular real content hash error diagnostics - **fixed** — Keep compilation dependency iterators disjoint - **fixed** — Align cache version semantics with webpack - **fixed** — Preserve ignored URL when import.meta.url is disabled - **fixed** — Avoid runtime lock deadlock in napi - **fixed** — Match compiler prefixes exactly in lazy compilation - **fixed** — Avoid injecting shared providers into worker entrypoints in Module Federation - **fixed** — Handle optional chains in member hook traversal - **fixed** — Support loader context APIs in parallel loaders ##### What's Changed ###### New Features 🎉 * feat: warn on unknown import.meta properties by @intellild in https://github.com/web-infra-dev/rspack/pull/14785 * feat: add builds for binding-linux-(ppc64,s390x)-gnu by @logonoff in https://github.com/web-infra-dev/rspack/pull/14962 * feat(create-rspack): support --no-git by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15133 * feat: support caseSensitive in import.meta.glob by @intellild in https://github.com/web-infra-dev/rspack/pull/14811 ###### Performance 🚀 * perf(copy-plugin): cache and order static patterns by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15051 * perf: limit incremental HMR asset processing by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15063 * perf: avoid unnecessary call wrappers for runtime helpers by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15065 * perf: cache compilation assets proxy by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15070 * perf(cache): avoid copying aligned archive buffers by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15024 * perf(json): avoid duplicating export dependency data by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15023 * perf: improve source map convert performance by @intellild in https://github.com/web-infra-dev/rspack/pull/15138 ###### Bug Fixes 🐞 * fix: improve circular real content hash error diagnostics by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14973 * fix: keep compilation dependency iterators disjoint by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15072 * fix(cache): align cache version semantics with webpack by @hardfist in https://github.com/web-infra-dev/rspack/pull/15000 * fix: preserve ignored URL when import.meta.url is disabled by @intellild in https://github.com/web-infra-dev/rspack/pull/15075 * fix(napi): avoid runtime lock deadlock by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15077 * fix(lazy): match compiler prefixes exactly by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15073 * fix(mf): avoid injecting shared providers into worker entrypoints by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15059 * fix: handle optional chains in member hook traversal by @zhsama in https://github.com/web-infra-dev/rspack/pull/15076 * fix: support loader context APIs in parallel loaders by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15092 * fix: warn on invalid chunk names by @HashemKhalifa in https://github.com/web-infra-dev/rspack/pull/14854 * fix: preserve imports in impure class expressions by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15098 * fix: preserve worker entrypoints when async chunks are disabled by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15096 * fix: align loader context docs and types with implementation by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15095 * fix(rstest): make import.meta.rstest resolver optional by @9aoy in https://github.com/web-infra-dev/rspack/pull/15097 * fix: handle context changes in import.meta.glob hooks by @intellild in https://github.com/web-infra-dev/rspack/pull/14897 * fix(types): align public API docs with declarations by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15107 * fix: preserve worker entrypoints during module deduplication by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14902 * fix(cli): restore config key completions in defineConfig by @upupming in https://github.com/web-infra-dev/rspack/pull/15140 * fix: deduplicate parse errors by source range by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15146 ###### Refactor 🔨 * refactor: extract parser options with AstObject derive by @intellild in https://github.com/web-infra-dev/rspack/pull/14886 * refactor: remove dead Rust code with Hawk by _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.9]_ ### v2.1.8 - Date: 2026-08-04 - Version: v2.1.8 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.8 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.8 - **added** — Support cache.name and cache.storage.location options to align with webpack's persistent cache semantics - **added** — Emit css.c and css.r in the hot-update manifest for precise CSS updates - **added** — Inject module origin for import.meta.rstest - **changed** — cache.storage.directory is now the base directory, with final cache location defaulting to / - **fixed** — Preserve entry dependency identity in binding - **fixed** — Preserve Lightning CSS license comments in loader - **fixed** — Add missing CJS interop runtime requirement for ESM - **fixed** — Avoid dead require bootstrap in runtime - **fixed** — Preserve collision-free createRequire imports in runtime - **fixed** — Clean up compilation-scoped plugin caches - **fixed** — Hoist test API imports by source order in rstest - **fixed** — Release custom runtime module generators on close in binding - **fixed** — Preserve context exports in rspack runtime mode - **fixed** — Correct full-hash chunk filenames in runtime - **fixed** — Use POSIX asset keys in copy-plugin - **fixed** — Remove redundant runtime declarations - **fixed** — Handle SharedWorker string name option - **fixed** — Avoid runtime scope conflicts in module factories - **fixed** — Preserve direct exports bindings ##### Highlights ###### Persistent cache storage options now align with webpack Rspack now supports `cache.name` and `cache.storage.location`, aligning with webpack's persistent cache semantics. `cache.storage.directory` is now the base directory, while the final cache location defaults to `/`. Default cache paths remain unchanged. If you previously used `storage.directory` as the exact cache path, migrate it to `storage.location`. Existing cache data is not migrated automatically. ```diff cache: { type: 'persistent', storage: { type: 'filesystem', - directory: '/custom/cache', + location: '/custom/cache', }, } ``` ##### What's Changed ###### New Features 🎉 * feat(rstest): inject module origin for import.meta.rstest by @9aoy in https://github.com/web-infra-dev/rspack/pull/15006 * feat: align persistent cache storage options with webpack by @hardfist in https://github.com/web-infra-dev/rspack/pull/15049 * feat(hmr): emit css.c / css.r in the hot-update manifest for precise CSS updates by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14682 ###### Performance 🚀 * perf: avoid cloning Lightning CSS stylesheet AST by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14982 * perf: avoid cloning CSS module lists during ordering by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14984 * perf(copy): offload asset reads by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15022 * perf: share source across linking diagnostics by @hardfist in https://github.com/web-infra-dev/rspack/pull/15048 ###### Bug Fixes 🐞 * fix(binding): preserve entry dependency identity by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/14964 * fix(loader): preserve lightningcss license comments by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14980 * fix(esm): add missing CJS interop runtime requirement by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14978 * fix(runtime): avoid dead require bootstrap by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14991 * fix(runtime): preserve collision-free createRequire imports by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14994 * fix: clean up compilation-scoped plugin caches by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/14999 * fix(rstest): hoist test API imports by source order by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/15007 * fix(binding): release custom runtime module generators on close by @SyMind in https://github.com/web-infra-dev/rspack/pull/15008 * fix: preserve context exports in rspack runtime mode by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15001 * fix(runtime): correct full-hash chunk filenames by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/14997 * fix(copy-plugin): use POSIX asset keys by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15015 * fix(runtime): remove redundant runtime declarations by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14993 * fix(worker): handle SharedWorker string name option by @elecmonkey in https://github.com/web-infra-dev/rspack/pull/15012 * fix: avoid runtime scope conflicts in module factories by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15002 * fix: preserve direct exports bindings by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/15003 * fix(dll): serialize buildMeta.defaultObject as redirect-warn by @tusharsingh308 in https://github.com/web-infra-dev/rspack/pull/15016 * fix(json): match webpack source map behavior for generated modules by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/15014 * fix: keep property name when global is used in object shorthand by @lazerg in https://github.com/web-infra-dev/rspack/pull/15054 * fix: prevent compiler abort for exported rspackRequire by @LingyuCoder i _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.8]_ ### v2.1.7 - Date: 2026-07-29 - Version: v2.1.7 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.7 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.7 - **removed** — Remove the import.meta.env experimental feature that was introduced in Rspack 2.1.6 - **changed** — Share source code across diagnostics to improve performance - **fixed** — Release module graph connection wrappers > **Notice:** The `import.meta.env` experimental feature introduced in Rspack 2.1.6 has been removed in Rspack 2.1.7. ##### What's Changed ###### Performance 🚀 * perf: share source code across diagnostics by @hardfist in https://github.com/web-infra-dev/rspack/pull/14967 ###### Bug Fixes 🐞 * fix: revert "feat: support import.meta.env" by @intellild in https://github.com/web-infra-dev/rspack/pull/14975 * fix(binding): release module graph connection wrappers by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14965 ###### Other Changes * chore: release version 2.1.6 by @SyMind in https://github.com/web-infra-dev/rspack/pull/14966 **Full Changelog**: https://github.com/web-infra-dev/rspack/compare/v2.1.6...v2.1.7 ### v2.1.6 - Date: 2026-07-28 - Version: v2.1.6 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.6 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.6 - **added** — Support import.meta.env - **changed** — Cache module concatenation analysis across roots - **changed** — Reuse module concatenation search state - **changed** — Reduce module concatenation hot-path overhead - **fixed** — Materialize namespace object for concatenated modules - **fixed** — Parse preserved createRequire arguments - **fixed** — Invalidate module hashes when assigning deterministic and natural ids - **fixed** — Disable incremental chunk assets for entry fullhash filenames - **fixed** — Propagate asset emit errors - **fixed** — Avoid JavaScript output for URL-only assets - **fixed** — Avoid worker external facade in bundleless output - **fixed** — Execute worker entry modules in modern-module output - **fixed** — Preserve defineConfig inference in CLI - **fixed** — Preserve structured swc diagnostics in swc-loader - **fixed** — Respect DllPlugin context for concatenated modules - **fixed** — Scope maxVersions by compiler using compilerPath in cache ##### What's Changed ###### New Features 🎉 * feat: support import.meta.env by @intellild in https://github.com/web-infra-dev/rspack/pull/14483 ###### Performance 🚀 * perf: cache module concatenation analysis across roots by @ScriptedAlchemy in https://github.com/web-infra-dev/rspack/pull/14832 * perf: reuse module concatenation search state by @ScriptedAlchemy in https://github.com/web-infra-dev/rspack/pull/14833 * perf: reduce module concatenation hot-path overhead by @ScriptedAlchemy in https://github.com/web-infra-dev/rspack/pull/14834 ###### Bug Fixes 🐞 * fix: materialize namespace object for concatenated modules by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14882 * fix: parse preserved createRequire arguments by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14813 * fix: invalidate module hashes when assigning deterministic and natural ids by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14878 * fix: disable incremental chunk assets for entry fullhash filenames by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14890 * fix: propagate asset emit errors by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14891 * fix(asset): avoid JavaScript output for URL-only assets by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14885 * fix(rslib): avoid worker external facade in bundleless output by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14900 * fix: execute worker entry modules in modern-module output by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14876 * fix(cli): preserve defineConfig inference by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14924 * fix(swc-loader): preserve structured swc diagnostics by @SyMind in https://github.com/web-infra-dev/rspack/pull/14921 * fix: respect DllPlugin context for concatenated modules by @hardfist in https://github.com/web-infra-dev/rspack/pull/14923 * fix(ci): resolve the binary-size base for stacked PRs by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14903 * fix(cache): scope maxVersions by compiler using compilerPath by @hardfist in https://github.com/web-infra-dev/rspack/pull/14954 ###### Refactor 🔨 * refactor(esm-library): remove redundant module marking by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14875 * refactor(runtime): collect runtime module variables from templates by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14917 * refactor(runtime): simplify modern-module output by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14741 ###### Document 📖 * docs: recommend TypeScript 7 for ts-checker-rspack-plugin by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14901 * docs: refresh Rstack slogan by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14928 * docs: mention Vue DevTools integration by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14932 * docs: clarify resolve.modules behavior by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14953 * docs: fix formatting in split-chunks-plugin.mdx by @davidjb in https://github.com/web-infra-dev/rspack/pull/14963 ###### Other Changes * chore(deps): update dependency @module-federation/runtime-tools to v2.8.0 by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14848 * chore(deps): update rust crate either to 1.16.0 by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14693 * test(module-concat): add concatenation benchmark baselines by @@ScriptedAlchemy in https://github.com/web-infra-dev/rspack/pull/14831 * chore(ci): upload ci-profile binary size from main CI by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14868 * chore(deps): upgrade Rslib to 1.0.0-beta.1 by @Timeless0911 in https://github.com/web-infra-dev/rspack/pull/14925 * chore(deps): update patch npm dependencies by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/148 _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.6]_ ### v2.1.5 - Date: 2026-07-21 - Version: v2.1.5 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.5 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.5 - **fixed** — Respect runtime mode in mf identifiers - **fixed** — Preserve multiple referenced client exports in rsc - **fixed** — Preserve createRequire().resolve with literal import.meta.url when requireResolve is disabled - **fixed** — Preserve inline match resource imports in css - **fixed** — Short-circuit optional import.meta calls - **fixed** — Preserve exports for dynamic client references in rsc - **fixed** — Avoid live chunk access when serializing stale stats - **fixed** — Register hoisted mocks before importActual imports in rstest - **fixed** — Run FsWatcher on a single owner task to fix concurrent &mut races - **fixed** — Add module type when options are omitted in module output for worker - **fixed** — Include output path in chunk render cache keys - **fixed** — Support real content hash update hooks ##### What's Changed ###### Bug Fixes 🐞 * fix: respect runtime mode in mf identifiers by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14782 * fix(rsc): preserve multiple referenced client exports by @SyMind in https://github.com/web-infra-dev/rspack/pull/14794 * fix: preserve createRequire().resolve with literal import.meta.url when requireResolve is disabled by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14783 * fix(css): preserve inline match resource imports by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14803 * fix: short-circuit optional import.meta calls by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14806 * fix(rsc): preserve exports for dynamic client references by @SyMind in https://github.com/web-infra-dev/rspack/pull/14807 * fix(stats): avoid live chunk access when serializing stale stats by @SyMind in https://github.com/web-infra-dev/rspack/pull/14808 * fix(rstest): register hoisted mocks before importActual imports by @fi3ework in https://github.com/web-infra-dev/rspack/pull/14810 * fix(watcher): run FsWatcher on a single owner task to fix concurrent &mut races by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14829 * fix(worker): add module type when options are omitted in module output by @elecmonkey in https://github.com/web-infra-dev/rspack/pull/14874 * fix: include output path in chunk render cache keys by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14877 * fix: support real content hash update hooks by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14660 ###### Refactor 🔨 * refactor(binding): remove compilation pointer from async dependency block by @SyMind in https://github.com/web-infra-dev/rspack/pull/14797 * refactor(core): improve referenced export data struct by @SyMind in https://github.com/web-infra-dev/rspack/pull/14796 ###### Other Changes * chore(skills): add webpack test gap diff script by @intellild in https://github.com/web-infra-dev/rspack/pull/14805 * chore: update Rsdoctor diff action version by @yifancong in https://github.com/web-infra-dev/rspack/pull/14812 * chore(deps): update napi by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14837 * chore(deps): update dependency @rslint/core to v0.7.0 by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14849 * chore: update simd-json and value-trait to fix stringify issue for CPUs without AVX/SSE4 capabilities by @intellild in https://github.com/web-infra-dev/rspack/pull/14828 * chore: add rspack perf codspeed goal skill by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14550 **Full Changelog**: https://github.com/web-infra-dev/rspack/compare/v2.1.4...v2.1.5 ### v2.1.4 - Date: 2026-07-14 - Version: v2.1.4 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.4 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.4 - **added** — Support fine-grained import.meta parser options allowing each known import.meta property to be configured independently - **added** — Support static worker new URL output with module.parser.javascript.worker accepting an object form with alias and url - **added** — Support logical assignment for chunk loading global in runtime - **changed** — Enable parallel wasmtime compilation for improved performance - **changed** — Optimize ESM linking passes - **fixed** — Clean up runtime global rendering - **fixed** — Clean up chunk wrappers when compiler is garbage collected - **fixed** — Enable runtime mode ESM context imports - **fixed** — Revert Module Federation runtime identifiers - **fixed** — Include paths in native filesystem errors - **fixed** — Respect RSPACK_BINDING in loader workers - **fixed** — Invalidate the target compiler for lazy compilation - **changed** — Deduplicate repeated dynamic reexport code - **changed** — Reduce hook macro expansion size and optimize performance ##### Highlights ###### Fine-grained `import.meta` parser options `module.parser.javascript.importMeta` now accepts an object so each known `import.meta` property can be configured independently, on top of the existing `true` / `false` / `'preserve-unknown'` values. Properties set to `false` are preserved for runtime evaluation, omitted properties keep their default behavior, and unknown properties are preserved. Both webpack-compatible keys (`dirname`, `filename`, `main`, `url`, `webpack`, `webpackContext`) and Rspack-specific keys (`rspackHash`, `rspackPublicPath`, `glob`, ...) are supported. ```js title="rspack.config.mjs" export default { module: { parser: { javascript: { importMeta: { // keep `import.meta.url` for runtime evaluation url: false, // keep the compile-time replacement of `import.meta.webpack` webpack: true, }, }, }, }, }; ``` ###### Static worker URL output `module.parser.javascript.worker` now accepts an object form with `alias` and `url`, alongside the existing `boolean` and `string[]` forms. With `url: 'new-url-relative'` and `output.module` enabled, Rspack emits a static `new URL()` expression for `new Worker(new URL(..., import.meta.url))` instead of runtime code, honoring `output.publicPath` and `output.workerPublicPath`. ```js title="rspack.config.mjs" export default { output: { module: true, chunkFilename: '[name].bundle.js', }, module: { parser: { javascript: { worker: { url: 'new-url-relative', }, }, }, }, }; ``` ```js new Worker(new URL('./worker.js', import.meta.url)); // would become 👇 new Worker(new URL('./worker.bundle.js', import.meta.url)); ``` ##### What's Changed ###### New Features 🎉 * feat(runtime): support logical assignment for chunk loading global by @fireairforce in https://github.com/web-infra-dev/rspack/pull/14655 * feat: support persistent cache for module hashes by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14717 * feat: support static worker new URL output by @intellild in https://github.com/web-infra-dev/rspack/pull/14728 * feat: support fine-grained import.meta parser options by @intellild in https://github.com/web-infra-dev/rspack/pull/14631 ###### Performance 🚀 * perf(swc): enable parallel wasmtime compilation by @hardfist in https://github.com/web-infra-dev/rspack/pull/14716 * perf(hook): reduce hook macro expansion size and optimize performance by @intellild in https://github.com/web-infra-dev/rspack/pull/14633 * perf: optimize ESM linking passes by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14758 * perf: deduplicate repeated dynamic reexport code by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14748 ###### Bug Fixes 🐞 * fix(ci): pick binary-size base by build-triggering commit by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14715 * fix: clean up runtime global rendering by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14735 * fix(binding): clean up chunk wrappers when compiler is GCed by @SyMind in https://github.com/web-infra-dev/rspack/pull/14736 * fix: enable runtime mode esm context imports by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14740 * fix: revert Module Federation runtime identifiers by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14761 * fix(fs): include paths in native filesystem errors by @hardfist in https://github.com/web-infra-dev/rspack/pull/14760 * fix: respect RSPACK_BINDING in loader workers by @hardfist in https://github.com/web-infra-dev/rspack/pull/14775 * fix: invalidate the target compiler for lazy compilation by @Kanary-channelio in https://github.com/web-infra-dev/rspack/pull/14781 ###### Refactor 🔨 * refactor(binding): avoid unsafe compilation access in chunk and module by @SyMind in https://github.com/web-infra- _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.4]_ ### v2.1.3 - Date: 2026-07-07 - Version: v2.1.3 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.3 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.3 - **added** — Add name/value accessors to ESMExportSpecifierDependency - **added** — Expose the real Chunk instance to filename functions - **changed** — Erase js tap storage types to reduce binary size - **changed** — Build rspack source maps directly - **changed** — Optimize module hash creation - **changed** — Pre-size per-module maps and vecs in mangle_exports - **fixed** — Update runtime context during hot updates - **fixed** — Inline-value check must precede deferred pure checks in concatenation - **fixed** — Skip re-applying unchanged CSS during HMR - **fixed** — Preserve asset bytes for binary files - **fixed** — Dedupe link HMR stylesheets in CSS - **fixed** — Emit manifest assets with forward-slash names on Windows - **fixed** — Unwrap dynamic source-phase imports in modern-module output - **fixed** — Preserve static source-phase external bindings in esm_library - **fixed** — Distinguish css wrapper sourcemap names - **fixed** — Keep path data chunk compatible in binding ##### What's Changed ###### New Features 🎉 * feat: add name/value accessors to ESMExportSpecifierDependency ([#14641](https://github.com/web-infra-dev/rspack/pull/14641) by @yashwanth195) * feat(core): expose the real Chunk instance to filename functions ([#14549](https://github.com/web-infra-dev/rspack/pull/14549) by @JSerFeng) ###### Performance 🚀 * perf: erase js tap storage types to reduce binary size ([#14636](https://github.com/web-infra-dev/rspack/pull/14636) by @intellild) * perf: build rspack source maps directly ([#14621](https://github.com/web-infra-dev/rspack/pull/14621) by @intellild) * perf: optimize module hash creation ([#14654](https://github.com/web-infra-dev/rspack/pull/14654) by @LingyuCoder) * perf(mangle_exports): pre-size per-module maps and vecs ([#14705](https://github.com/web-infra-dev/rspack/pull/14705) by @stormslowly) ###### Bug Fixes 🐞 * fix: update runtime context during hot updates ([#14644](https://github.com/web-infra-dev/rspack/pull/14644) by @LingyuCoder) * fix(concatenation): inline-value check must precede deferred pure checks ([#14663](https://github.com/web-infra-dev/rspack/pull/14663) by @guru-irl) * fix(css): skip re-applying unchanged CSS during HMR ([#14580](https://github.com/web-infra-dev/rspack/pull/14580) by @stormslowly) * fix(asset): preserve asset bytes for binary files ([#14670](https://github.com/web-infra-dev/rspack/pull/14670) by @hardfist) * fix(css): dedupe link HMR stylesheets ([#14666](https://github.com/web-infra-dev/rspack/pull/14666) by @intellild) * fix(mf): emit manifest assets with forward-slash names on Windows ([#14667](https://github.com/web-infra-dev/rspack/pull/14667) by @johncarmack1984) * fix(esm_library): unwrap dynamic source-phase imports in modern-module output ([#14673](https://github.com/web-infra-dev/rspack/pull/14673) by @elecmonkey) * fix(esm_library): preserve static source-phase external bindings ([#14674](https://github.com/web-infra-dev/rspack/pull/14674) by @elecmonkey) * fix(bench): pin glibc string-func dispatch to stabilize simulation benches ([#14704](https://github.com/web-infra-dev/rspack/pull/14704) by @stormslowly) * fix(css): distinguish css wrapper sourcemap names ([#14675](https://github.com/web-infra-dev/rspack/pull/14675) by @intellild) * fix(binding): keep path data chunk compatible ([#14698](https://github.com/web-infra-dev/rspack/pull/14698) by @JSerFeng) ###### Refactor 🔨 * refactor: use rspack runtime module prefix ([#14630](https://github.com/web-infra-dev/rspack/pull/14630) by @LingyuCoder) * refactor: split content hash from std Hash ([#14384](https://github.com/web-infra-dev/rspack/pull/14384) by @intellild) * refactor: rename hash objects for clearer semantics ([#14642](https://github.com/web-infra-dev/rspack/pull/14642) by @intellild) * refactor: use rspack scheme for source map defaults ([#14635](https://github.com/web-infra-dev/rspack/pull/14635) by @LingyuCoder) * refactor(runtime): collect runtime writes from ejs define ([#14651](https://github.com/web-infra-dev/rspack/pull/14651) by @LingyuCoder) * refactor(napi): remove napi tokio runtime dependency ([#14696](https://github.com/web-infra-dev/rspack/pull/14696) by @hardfist) ###### Other Changes * test: register misc bundle benchmark ([#14632](https://github.com/web-infra-dev/rspack/pull/14632) by @hardfist) * chore(release): stream per-package publish output ([#14585](https://github.com/web-infra-dev/rspack/pull/14585) by @stormslowly) * chore(deps): update github-actions ([#14638](https://github.com/web-infra-dev/rspack/pull/14638) by @renovate[bot]) * ci: replace rust-cache with sccache (TOS) on self-hosted runners ([#14567](https://github.com/web-infra-dev/rspack/pull/14567) by @stormslowly) * ci: reset lynx-infra/cache action to d6bd70b ([#14646](https://github.com/web-infra-dev/rspack/pull/14646) by @stormslowly) * chore(ci): run binary size limit on linux mini runner ([#14648](https://github.com/web-infra-dev/rspack/pul _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.3]_ ### v2.1.2 - Date: 2026-06-30 - Version: v2.1.2 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.2 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.2 - **added** — Support `import.meta` style module variables including `import.meta.rspackPublicPath`, `import.meta.rspackBaseUri`, `import.meta.rspackShareScopes`, `import.meta.rspackInitSharing`, `import.meta.rspackNonce`, `import.meta.rspackUniqueId`, `import.meta.rspackVersion`, and `import.meta.rspackHash` - **changed** — Deduplicate runtime module macro glue for improved performance - **changed** — Avoid cloning side effects artifact in module concatenation - **fixed** — Inject runtime require into browser MF runtime - **fixed** — Preserve import phase in dynamic import external rendering - **fixed** — Empty references export for cjs and dynamic import tree shaking ##### What's Changed ##### Highlights 💡 ###### Support `import.meta` style module variables

Rspack now exposes more module variables through import.meta, which aligns better with the ESM specification than CommonJS-style injected globals. When authoring ESM modules, import.meta is now the recommended way to access these runtime values.

The newly supported import.meta properties are:

New import.meta API | Existing runtime variable -- | -- `import.meta.rspackPublicPath` | `__webpack_public_path__` `import.meta.rspackBaseUri` | `__webpack_base_uri__` `import.meta.rspackShareScopes` | `__webpack_share_scopes__` `import.meta.rspackInitSharing` | `__webpack_init_sharing__` `import.meta.rspackNonce` | `__webpack_nonce__` `import.meta.rspackUniqueId` | `__rspack_unique_id__` `import.meta.rspackVersion` | `__rspack_version__` `import.meta.rspackHash` | `__webpack_hash__` ###### New Features 🎉 * feat: support `import.meta` style module variables ([#14539](https://github.com/web-infra-dev/rspack/pull/14539) by @LingyuCoder) ###### Performance 🚀 * perf: deduplicate runtime module macro glue ([#14620](https://github.com/web-infra-dev/rspack/pull/14620) by @intellild) * perf: avoid cloning side effects artifact in module concatenation ([#14622](https://github.com/web-infra-dev/rspack/pull/14622) by @hardfist) ###### Bug Fixes 🐞 * fix(browser): inject runtime require into browser MF runtime ([#14590](https://github.com/web-infra-dev/rspack/pull/14590) by @CPunisher) * fix(ci): build wasm in release debug so the wasm binding gets published ([#14614](https://github.com/web-infra-dev/rspack/pull/14614) by @stormslowly) * fix(rslib): preserve import phase in dynamic import external rendering ([#14615](https://github.com/web-infra-dev/rspack/pull/14615) by @elecmonkey) * fix: empty references export for cjs and dynamic import tree shaking ([#14629](https://github.com/web-infra-dev/rspack/pull/14629) by @ahabhgk) ###### Document 📖 * docs: document asset/resource emit generator option ([#14602](https://github.com/web-infra-dev/rspack/pull/14602) by @chenjiahan) * docs: document json parser parse option ([#14606](https://github.com/web-infra-dev/rspack/pull/14606) by @chenjiahan) * docs: document more rule use options ([#14610](https://github.com/web-infra-dev/rspack/pull/14610) by @chenjiahan) * docs: update module variable docs for import.meta ([#14618](https://github.com/web-infra-dev/rspack/pull/14618) by @LingyuCoder) * docs: enable Rspress anchor checks ([#14627](https://github.com/web-infra-dev/rspack/pull/14627) by @chenjiahan) ###### Other Changes * chore(deps): update patch npm dependencies ([#14595](https://github.com/web-infra-dev/rspack/pull/14595) by @renovate[bot]) * chore(deps): update dependency @babel/preset-react to ^7.29.7 ([#14597](https://github.com/web-infra-dev/rspack/pull/14597) by @renovate[bot]) * chore(deps): update dependency @ast-grep/napi to ^0.44.0 ([#14596](https://github.com/web-infra-dev/rspack/pull/14596) by @renovate[bot]) * chore(deps): update dependency @rsbuild/core to v2.1.1 ([#14603](https://github.com/web-infra-dev/rspack/pull/14603) by @renovate[bot]) * chore(deps): update dependency @rspack/dev-server to ^2.1.0 ([#14604](https://github.com/web-infra-dev/rspack/pull/14604) by @renovate[bot]) * chore(deps): update dependency @shikijs/transformers to ^4.3.0 - autoclosed ([#14605](https://github.com/web-infra-dev/rspack/pull/14605) by @renovate[bot]) * chore(deps): update dependency mermaid to ^11.16.0 ([#14607](https://github.com/web-infra-dev/rspack/pull/14607) by @renovate[bot]) * chore(deps): update dependency ts-checker-rspack-plugin to ^1.5.1 ([#14608](https://github.com/web-infra-dev/rspack/pull/14608) by @renovate[bot]) * chore(deps): update dependency @rsbuild/plugin-sass to v2 ([#14609](https://github.com/web-infra-dev/rspack/pull/14609) by @renovate[bot]) * chore: remove o _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.2]_ ### v2.1.1 - Date: 2026-06-27 - Version: v2.1.1 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.1 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.1 - **added** — Add dependencyId and loc to export usage edges in rsdoctor - **changed** — Add persistent cache for SourceMapDevToolPlugin - **fixed** — Add guard for link.parentNode in css runtime - **fixed** — Revert cjs export assignment side effects optimization ##### What's Changed ###### New Features 🎉 * feat(rsdoctor): add dependencyId and loc to export usage edges by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14577 ###### Performance 🚀 * perf(devtool): add persistent cache for SourceMapDevToolPlugin by @SyMind in https://github.com/web-infra-dev/rspack/pull/14473 ###### Bug Fixes 🐞 * fix(css): add guard for link.parentNode in css runtime by @BeiyanYunyi in https://github.com/web-infra-dev/rspack/pull/14566 * fix: revert cjs export assignment side effects optimization by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14600 ###### Other Changes * docs: v2.1 release blog by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14527 * refactor(runtime): structure runtime requirements by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14574 * chore(deps): update dependency @rslint/core to v0.6.3 by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14594 * chore(deps): update dependency @module-federation/runtime-tools to v2.6.0 by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14598 ##### New Contributors * @BeiyanYunyi made their first contribution in https://github.com/web-infra-dev/rspack/pull/14566 **Full Changelog**: https://github.com/web-infra-dev/rspack/compare/v2.1.0...v2.1.1 ### v2.1.0 - Date: 2026-06-26 - Version: v2.1.0 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.0 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.0 - **added** — Expose module error JS API - **added** — Log persistent cache read and write timings - **added** — Expose getProvidedExports() to JS API - **added** — Support drop inactive branch dependencies for member expressions - **added** — Introduce experimental.runtimeMode - **added** — Support branch guarded export presence for `in` on ESM imports - **added** — Bump swc to support react compiler - **added** — Expose export usage graph to rsdoctor - **added** — Add maxAge and maxGenerations for persistent cache cleanup - **added** — Support riscv64 targets - **changed** — Enable pureFunctions by default - **changed** — Make persistent cache max generations default to 3 - **changed** — Rename persistent cache maxGenerations to maxVersions - **changed** — Harden persistent cache version cleanup with typed version - **changed** — Make stale version cleanup fire-and-forget - **fixed** — Preserve inline source content for transform sourcemaps - **fixed** — Remove webpackSource and webpackDefer magic comments - **fixed** — Apply global overrideStrict for ContextModule - **fixed** — Filter ignored-subtree events that emit a spurious folder change in watcher - **fixed** — Handle nested pure function calls in tree-shaking ##### What's Changed ##### 🎉 See [Announcing Rspack 2.1](https://rspack.rs/blog/announcing-2-1) for more details. ###### New Features 🎉 * feat: expose module error JS API by @SyMind in https://github.com/web-infra-dev/rspack/pull/14351 * feat(cache): log persistent cache read and write timings by @hardfist in https://github.com/web-infra-dev/rspack/pull/14314 * feat(module_graph): expose `getProvidedExports()` to JS API by @logonoff in https://github.com/web-infra-dev/rspack/pull/14349 * feat: support drop inactive branch dependencies for member expr by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14382 * feat(runtime): introduce experimental.runtimeMode by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14254 * feat: support branch guarded export presence for `in` on ESM imports by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14426 * feat: bump swc to support react compiler by @CPunisher in https://github.com/web-infra-dev/rspack/pull/14435 * feat(runtime): runtime internals of rspack runtime mode by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14427 * feat(rsdoctor): expose export usage graph by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14291 * feat: enable pureFunctions by default by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14465 * feat(cache): add maxAge and maxGenerations for persistent cache cleanup by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/14296 * feat: make persistent cache max generations default to 3 by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14534 * feat: rename persistent cache `maxGenerations` to `maxVersions` by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14545 * feat: harden persistent cache version cleanup with typed version by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14552 * feat: support riscv64 targets by @swwind in https://github.com/web-infra-dev/rspack/pull/14447 * feat(cache): make stale version cleanup fire-and-forget by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14564 ###### Performance 🚀 * perf: remove serde json by @SyMind in https://github.com/web-infra-dev/rspack/pull/14272 * perf: use mask intersects instead of flag iteration for scope globals by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14353 * perf: add ASCII fast path for dependency location column computation by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14355 * perf: force DFA automaton for real content hash scanning by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14356 * perf(core): reduce memcpy overhead by @hardfist in https://github.com/web-infra-dev/rspack/pull/14381 * perf: reduce flag dependency usage key allocations by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14417 * perf: reduce build chunk graph preparation work by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14421 * perf(sources): avoid cloning source maps with borrowed fields by @SyMind in https://github.com/web-infra-dev/rspack/pull/14380 * perf: optimize module concatenation traversal by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14422 * perf(loader-runner): cache esm loader imports by @hardfist in https://github.com/web-infra-dev/rspack/pull/14434 * perf(core): optimize resource parsing by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14456 * perf(ci): drop redundant cargo check from rust CI by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14461 * perf: avoid JavaScriptTracer overhead when tracing is disabled by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14468 * perf(loader-runner): reduce loader object construction overhead by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14477 * perf: optimize compilation entrypoints getter by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14485 * perf: redu _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.0]_ ### v2.1.0-beta.0 - Date: 2026-06-18 - Version: v2.1.0-beta.0 - Original notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.0-beta.0 - Permalink: https://whatsnew.fyi/product/rspack/releases/v2.1.0-beta.0 - **added** — Support React Compiler in builtin:swc-loader - **added** — Expose module error JS API - **added** — Log persistent cache read and write timings - **added** — Expose getProvidedExports() to JS API - **added** — Support drop inactive branch dependencies for member expr - **added** — Introduce experimental.runtimeMode - **added** — Support branch guarded export presence for in on ESM imports - **added** — Add maxAge and maxGenerations for persistent cache cleanup - **changed** — Enable side-effect-free function analysis by default in production builds - **changed** — Bump swc to support react compiler - **fixed** — Preserve inline source content for transform sourcemaps - **fixed** — Remove webpackSource and webpackDefer magic comments - **fixed** — Apply global overrideStrict for ContextModule - **fixed** — Filter ignored-subtree events that emit a spurious folder change - **fixed** — Use ChunkWithSizeInfo delimiter in maxInitialSize chunk naming fallback path - **fixed** — Wait for in-flight build before closing compiler - **fixed** — Point wasi-worker-browser export to dist file - **fixed** — Handle nested pure function calls in tree-shaking - **fixed** — Cache import.meta filename and dirname outside eval ##### Highlights 💡 ###### Support React Compiler in `builtin:swc-loader` React projects can now use React Compiler directly through Rspack's built-in SWC loader. See the [React Compiler guide](https://rspack.rs/guide/tech/react#using-builtinswc-loader) for details. ```js export default { module: { rules: [ { test: /\.[cm]?[jt]sx?$/, loader: 'builtin:swc-loader', options: { jsc: { transform: { reactCompiler: true, }, }, }, }, ], }, }; ``` ###### Side-effect-free function analysis by default Rspack's side-effect-free function analysis is now enabled by default in production builds. It can detect pure function calls through the `#__NO_SIDE_EFFECTS__` notation and `pureFunctions` configuration, including exported functions across module boundaries. When the returned value is unused, Rspack can remove the call more reliably and improve tree shaking results without extra configuration. See [`experiments.pureFunctions`](https://rspack.rs/config/experiments#experimentspurefunctions) for details. ```js // lib.js /*@__NO_SIDE_EFFECTS__*/ export function call() { console.log('hi') } // barrel.js import { call } from './lib' const value = call() // if value is unused, call can be removed export { value } ``` image ##### What's Changed ###### New Features 🎉 * feat: expose module error JS API by @SyMind in https://github.com/web-infra-dev/rspack/pull/14351 * feat(cache): log persistent cache read and write timings by @hardfist in https://github.com/web-infra-dev/rspack/pull/14314 * feat(module_graph): expose `getProvidedExports()` to JS API by @logonoff in https://github.com/web-infra-dev/rspack/pull/14349 * feat: support drop inactive branch dependencies for member expr by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14382 * feat(runtime): introduce experimental.runtimeMode by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14254 * feat: support branch guarded export presence for `in` on ESM imports by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14426 * feat: bump swc to support react compiler by @CPunisher in https://github.com/web-infra-dev/rspack/pull/14435 * feat(runtime): runtime internals of rspack runtime mode by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14427 * feat(rsdoctor): expose export usage graph by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14291 * feat: enable pureFunctions by default by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/14465 * feat(cache): add maxAge and maxGenerations for persistent cache cleanup by @matthewdavis-oai in https://github.com/web-infra-dev/rspack/pull/14296 ###### Performance 🚀 * perf: remove serde json by @SyMind in https://github.com/web-infra-dev/rspack/pull/14272 * perf: use mask intersects instead of flag iteration for scope globals by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14353 * perf: add ASCII fast path for dependency location column computation by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14355 * perf: force DFA automaton for real content hash scanning by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14356 * perf(core): reduce memcpy overhead by @hardfist in https://github.com/web-infra-dev/rspack/pull/14381 * perf: reduce flag dependency usage key allocations by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14417 * perf: reduce build chunk graph preparation work by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14421 * perf(sources): avoid cloning source maps with borrowed fields by @SyMind in https://github.com/web-infra-dev/rspack/pull/14380 * perf: optimize module concatenation traversal by @Lingy _[Truncated at 4000 characters — full notes: https://github.com/web-infra-dev/rspack/releases/tag/v2.1.0-beta.0]_