web-infra-dev/rspack
 Watch   
 Star   
 Fork   
19 hours ago
rspack

v2.3.5

Highlights

Faster stats.toJson() for large builds

Rspack now generates default Stats JSON through a faster path and uses compact tables for module and dependency-reason data. In one anonymized production client build, the reason-data change reduced the median time of the first stats.toJson() call from 7.30 s to 2.75 s. #16906 · #16952 · #16976

Less overhead for parallel loaders

Rspack now reuses parsed loader requests within a compilation and cuts worker round trips for dependency updates, logging, and diagnostics. #16901 · #16933 · #16934 · #16936

More reliable HMR with lazy compilation

Rspack now keeps compact-hashed chunk IDs stable across rebuilds and handles reused chunk IDs during hot updates. This fixes crashes that could occur when lazy compilation activates a chunk in a build that uses workers. #16877 · #16884

What's Changed

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.3.4...v2.3.5

7 days ago
rspack

v2.3.4

Highlights

Smaller bundles

Rspack now produces smaller bundles with less runtime code on modern targets, skipping unnecessary helpers, and improved tree-shaking.

Clearer plugin, loader, and build diagnostics

Diagnostics across built-in plugins and loaders now include plugin names, loader names, and source filenames so issues are easier to trace back to configuration and source files.

Solid v2 support

Rspack now supports Solid v2 through solid-loader. create-rspack now includes solid-js and solid-ts starter templates. You can now create Solid projects with create-rspack:

npm create rspack@latest -- --template solid-ts

See #16752.

What's Changed

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.3.3...v2.3.4

14 days ago
rspack

v2.3.3

Highlights

Breaking change: webpack-compatible HTTP lockfiles

HTTP module lockfiles and content cache filenames now match webpack, allowing existing webpack lockfiles and cached resources to be reused together. The previous Rspack format is no longer supported: delete the old HTTP lockfile and content cache, rebuild with experiments.buildHttp.frozen: false, then review and commit the regenerated files before re-enabling frozen builds. See #16656.

Better tree shaking for dynamic imports

Rspack now tracks member usage through destructured dynamic-import namespaces, allowing unused nested exports to be removed more precisely. This covers awaited imports, destructured .then() parameters, and Promise.all() results. See #16574.

Faster HMR-enabled builds with repeated dynamic imports

Projects with many import() expressions targeting the same module avoid repeated chunk-group scans during HMR-enabled compilation. Rspack now caches loading-chunk lookups and reuses sibling chunk lists, addressing a compilation bottleneck that grew rapidly with the number of imports. See #16674.

Shared loader cache across compilers

Rspack now shares loader cache results between compilers in the same process. For example, in an SSR build, the client and server compilers can reuse loader transformations for shared source files, avoiding repeated work. Compilers can share results when using memory cache or the same persistent cache directory. See #16558.

What's Changed

Breaking Changes 🍭

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.3.2...v2.3.3

21 days ago
rspack

v2.3.2

Highlights 💡

More reliable HMR, fewer full-page reloads

HMR now handles code-splitting changes more reliably, reducing unnecessary full-page reloads when chunks are added or rearranged. Newly required chunks are loaded before HMR accept callbacks run, and changes to async chunk dependencies no longer cause unnecessary update propagation.

Experimental rule.as

The experimental rule.as option lets a matched resource use a different path for subsequent rule matching while preserving the original resource for file reading and loaders. For example, as: '[resource-path].txt' lets later .txt rules also process example.source.js. (#15917)

// rspack.config.mjs
export default {
  module: {
    rules: [
      {
        test: /\.source\.js$/,
        type: 'asset/source',
        as: '[resource-path].txt',
      },
      { test: /\.txt$/, use: './text-loader.js' },
    ],
  },
};

Here, example.source.js matches the later .txt rule as example.source.js.txt; text-loader.js still receives the contents of the original file.

Skip side-effect-free export * passthrough modules

Rspack can now bypass side-effect-free modules that only forward exports with export *, connecting directly to the underlying module.

Mark the package as side-effect-free in package.json:

{
  "sideEffects": false
}
// src/value.js
export const value = 42;

// src/passthrough.js
export * from './value.js';

// src/index.js
export * from './passthrough.js';

With optimization.sideEffects enabled (the default in production), the export * connection from index.js can now go directly to value.js, skipping passthrough.js.

What's Changed

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.3.1...v2.3.2

28 days ago
rspack

v2.3.1

What's Changed

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.3.0...v2.3.1

2026-10-29 15:53:43
rspack

v2.3.0

What's Changed

🎉 See Announcing Rspack 2.3 for more details.

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.2.9...v2.3.0

2026-10-27 10:18:25
rspack

v2.3.0-rc.0

What's Changed

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.3.0-beta.1...v2.3.0-rc.0

2026-10-22 16:12:00
rspack

v2.3.0-beta.1

What's Changed

Breaking Changes 🍭

Thefilter.code loader option (introduced in 2.3.0-beta.0) has been renamed tocodeFilter . If you are upgrading from 2.3.0-beta.0, replacefilter: { code: ... } withcodeFilter: ... in your loader config. No action is needed if you never usedfilter.code .

// 2.3.0-beta.0
{ loader: 'my-loader', filter: { code: 'customMacro(' } }

// 2.3.0-beta.1
{ loader: 'my-loader', codeFilter: 'customMacro(' }

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.3.0-beta.0...v2.3.0-beta.1

2026-10-20 17:26:01
rspack

v2.3.0-beta.0

Highlights

JavaScript parsing with SWC Next

Rspack now uses SWC Next for JavaScript parsing. This beta also includes follow-up compatibility fixes for block-scoped functions, parser source types, and legacy parser behavior. See #16089.

Content-based loader filtering

The new loader filter.code option accepts a string or regular expression and checks the loader's current input before running its normal transform. Loaders can skip files that do not contain the syntax or markers they need to process, avoiding unnecessary transformation work. For example, a loader that transforms customMacro() calls can use filter: { code: 'customMacro(' } to skip inputs without that marker. Pitch functions are unaffected. See #16073.

Better SplitChunks output

Named cache groups now remove redundant module copies from source chunks connected to the same shared chunk, reducing duplicate code in affected builds. Rspack also supports splitChunks.minRemainingSize to avoid splits that leave undersized chunks, bringing JavaScript and extracted CSS output closer to webpack. For example, an affected asynchronous CSS import now retains its expected controls.css filename in production. See #16075 and #15594.

Better watcher compatibility

Native and Node watch file systems now expose watchpack-compatible getTimes(), getTimeInfoEntries(), and collectTimeInfoEntries() APIs. With experiments.nativeWatcher, compiler.fileTimestamps, compiler.contextTimestamps, and the watcher's getInfo() now return real timestamp entries, improving compatibility with plugins that rely on watch metadata, such as ts-loader, webpack-virtual-modules, and vue-loader. The Node watcher also merges time-info entries deterministically so directory timestamps are preserved regardless of dependency iteration order. See the WatchFileSystem API documentation, #15754 and #16126.

Memory improvements and diagnostics

Rspack avoids retaining serialized source maps, reducing memory retained by source objects. Source handling also uses a source-wide UTF-16 index and removes its object pool. See #16072 and #16083.

New allocative-based memory diagnostics help identify which Rust data structures retain memory during builds and HMR updates. See the memory diagnostics guide to capture and analyze snapshots.

What's Changed

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Refactor 🔨

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.2.9...v2.3.0-beta.0

2026-10-13 15:43:47
rspack

v2.2.9

Highlights

Less duplicate code. Smaller bundles. 📦

Rspack's chunking algorithm has been improved to reduce duplicate modules across chunks. (#15885)

https://github.com/user-attachments/assets/0840ec5b-7eea-4d37-9053-cc5cef176103

Smaller package size

Rspack upgrades browserslist-rs and enables deflate compression for its browser data, reducing native binary by 2.13 MB (3.08%). (#16009)

What's Changed

New Features 🎉

Performance 🚀

Bug Fixes 🐞

Document 📖

Other Changes

New Contributors

Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.2.8...v2.2.9