v2.0.4
-
Inline const with module declarations (#14032): Previously, Rspack only inlined constant exports from leaf modules in the module graph. Now constant exports from any module can be inlined, even when that module also imports or re-exports other modules. In rare circular-reference cases this can make a TDZ error disappear, but we do not expect real projects to rely on TDZ errors, so Rspack prioritizes the optimization.
// constants.js import './setup'; export const ENABLE_EXPERIMENT = false; // entry.js import { ENABLE_EXPERIMENT } from './constants'; if (ENABLE_EXPERIMENT) { runExperiment(); } // Before: constants.js is not a leaf module, so the branch could keep // reading the imported binding. if (ENABLE_EXPERIMENT) { runExperiment(); } // Now: the constant can still be inlined, so dead branches are easier // to remove. if (false) { runExperiment(); }
-
Tree shake namespace default reexport (#13980): Previously, the
import * as a from './a'; export default a;pattern did not tree-shakeathrough the default export. Now Rspack further analyzes the default-exported namespace object and can remove unused exports from the original namespace module.// a.js export function used() {} export function unused() {} // bridge.js import * as a from './a'; export default a; // app.js import a from './bridge'; a.used(); // Before: both used and unused could be kept in the bundle. // Now: unused can be tree-shaken.
-
CSS global module type (#13988):
css/globalis useful when most selectors in a stylesheet should stay global, but you still want CSS Modules features for selected local selectors. This makes it easier to migrate existing global CSS gradually without turning every class name into a local scoped name.export default { module: { rules: [{ test: /\.global\.css$/i, type: 'css/global' }], }, };
/* style.global.css */ .button { color: red; } :local(.title) { font-weight: 600; }
.buttonstays global, while.titleis renamed as a local class. -
CSS Modules local ident options (#14009): CSS Modules now support local ident hash options such as hash function, digest, digest length, and salt. These options make generated class names more configurable and better aligned with webpack-compatible CSS Modules setups.
export default { module: { rules: [{ test: /\.module\.css$/i, type: 'css/module' }], generator: { 'css/module': { localIdentName: '[name]__[local]__[hash]', localIdentHashFunction: 'xxhash64', localIdentHashDigest: 'hex', localIdentHashDigestLength: 8, localIdentHashSalt: 'my-salt', }, }, }, };
- feat(css): add support for css/global module type by @intellild in https://github.com/web-infra-dev/rspack/pull/13988
- feat: tree shake namespace default reexport by @JSerFeng in https://github.com/web-infra-dev/rspack/pull/13980
- feat: inline const with module declarations by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14032
- feat(css): support CSS module local ident options by @intellild in https://github.com/web-infra-dev/rspack/pull/14009
- feat: circular modules info plugin by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14031
- perf: cache reserved name atom set by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14014
- perf: optimize flag dependency usage by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14052
- perf(cli): remove process title startup overhead by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14061
- perf(deps): unify duplicate Rust dependencies to reduce binary size by @intellild in https://github.com/web-infra-dev/rspack/pull/14012
- perf: improve split chunks cache group filtering by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14067
- perf: optimize mangle exports plugin by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14048
- perf(cli): lazy load json stream helpers by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14079
- perf: optimize named id assignment by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14075
- fix(rsc): skip client entry mismatch without injections by @SyMind in https://github.com/web-infra-dev/rspack/pull/14018
- fix(cli): write logger trace output to file by default by @hardfist in https://github.com/web-infra-dev/rspack/pull/14022
- fix(ci): repair broken rustup shim chain on macos-latest by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14040
- fix(stats): preserve sub-millisecond precision in logger time entries by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14049
- fix: import.meta.filename/dirname escape on windows by @ahabhgk in https://github.com/web-infra-dev/rspack/pull/14050
- fix(rsc): group client chunks by server-entry ownership by @SyMind in https://github.com/web-infra-dev/rspack/pull/13880
- fix(rslib): emit type-only isolated dts dependencies by @Timeless0911 in https://github.com/web-infra-dev/rspack/pull/14037
- fix(copy-plugin): support JS input file system for glob copies by @intellild in https://github.com/web-infra-dev/rspack/pull/14023
- fix: keep buildHttp imports bundled for node target by @SyMind in https://github.com/web-infra-dev/rspack/pull/14086
- docs: update config option types by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14060
- docs: update runtime plugin hooks by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14069
- docs(plugin-api): document module factory hooks by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14070
- docs(cli): update cli option descriptions by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14071
- docs(website): update core team profile by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14093
- security(ci): remove PR title lint workflow by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14016
- chore: add local rust benchmark script by @hardfist in https://github.com/web-infra-dev/rspack/pull/14007
- chore(ci): replace archived actions-rs/cargo with bare cargo invocations by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14017
- chore: release version 2.0.3 by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14015
- chore: add draft release notes skill by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14028
- chore(build): fix empty napi-binding.d.ts on subsequent builds by @stormslowly in https://github.com/web-infra-dev/rspack/pull/14027
- chore: bump rslint to 0.5.3 by @fansenze in https://github.com/web-infra-dev/rspack/pull/14034
- chore(deps): update swc crates by @hardfist in https://github.com/web-infra-dev/rspack/pull/14036
- chore(skill): add rspack performance optimization skill by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14047
- chore: upgrade swc from 64 to 66 by @hardfist in https://github.com/web-infra-dev/rspack/pull/14059
- chore(deps): update dependency @codspeed/vitest-plugin to ^5.4.0 by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14057
- chore(deps): update patch npm dependencies by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14055
- chore(deps): update dependency @playwright/test to v1.60.0 by @renovate[bot] in https://github.com/web-infra-dev/rspack/pull/14058
- chore: bump patch of swc_core and swc_typescript by @CPunisher in https://github.com/web-infra-dev/rspack/pull/14066
- test: add named ids codspeed benchmarks by @LingyuCoder in https://github.com/web-infra-dev/rspack/pull/14074
- chore(security): replace issues helper action by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14084
- chore(deps): bump rstack ecosystem ci action by @chenjiahan in https://github.com/web-infra-dev/rspack/pull/14092
Full Changelog: https://github.com/web-infra-dev/rspack/compare/v2.0.3...v2.0.4
@astrojs/cloudflare@13.5.3
-
#16801
d619277Thanks @ematipico! - Reverts a change to the esbuild dep-scan plugin that causedastro checkandastro buildto fail by making esbuild incorrectly bundlevirtual:modules (e.g. from expressive-code) -
Updated dependencies []:
- @astrojs/underscore-redirects@1.0.3
astro@6.3.6
-
#16774
8f77583Thanks @astrobot-houston! - Fixes markdown images with empty alt text () in content collections dropping thealtattribute entirely. Thealt=""attribute is now correctly preserved in the rendered HTML output, which is important for accessibility (indicating decorative images). -
#16776
3d10b5eThanks @matthewp! - Fixes HMR serving stale content when components are passed as props viagetStaticPaths() -
#16784
7453860Thanks @ematipico! - Improved the printing of the build time if it goes over the 60 seconds. -
#16665
3dbbceeThanks @Princesseuh! - Fixes remote SVG sources erroring withdangerouslyProcessSVGafter the v6.3 SVG-processing gate. The default Sharp service now resolves the output format from the source up-front when it can (URL extension,data:MIME, ESM metadata), and from the actual buffer at request time when it can't, so SVG sources pass through untouched without needing to setimage.dangerouslyProcessSVG: trueor an explicitformat="svg".The error message has also been updated to point at
format="svg"as the simpler workaround when an SVG source is encountered withoutdangerouslyProcessSVGenabled. -
#16777
1754b91Thanks @matthewp! - Fixes HMR serving stale content for dynamically imported components through barrel files -
#16730
068d924Thanks @harshagarwalnyu! - Fixes an issue where thefile()content loader did not generate a valid JSON Schema for collections whose JSON or YAML data is a top-level array instead of an object.
Release 2026-05-20 10:04
Release 2026-05-20 10:04
- deferred hydration (#7362) (5fa9e555f3) by @schiller-manuel
- router-core: params.priority route option as tie breaker in matching algorithm (#7411) (d533f87976) by @Sheraff
- fix route mismatch warnings and HMR route indexes (#7422) (b60eb36e59) by @schiller-manuel
- router-plugin: detect typed root route context for HMR (#7420) (8146db7e54) by @schiller-manuel
- router-core: hydrate before initial client route match (#7416) (d9cf9331b8) by @schiller-manuel
- update express and webpack-dev-server (#7443) (697c66b337) by @Sheraff
- update zod to v4.4.3 (#7441) (9f6258f23e) by @Sheraff
- update @rolldown/pluginutils to 1.0.1 (#7440) (fa48ea8d38) by @Sheraff
- update chokidar to v5 (#7439) (c0f439c59b) by @Sheraff
- update @swc/core in example/react/quickstart-webpack-file-based (#7434) (60ad69c8fa) by @Sheraff
- @tanstack/react-router@1.170.5
- @tanstack/react-start@1.168.7
- @tanstack/react-start-client@1.168.0
- @tanstack/react-start-rsc@0.1.7
- @tanstack/react-start-server@1.167.5
- @tanstack/router-cli@1.167.6
- @tanstack/router-core@1.171.3
- @tanstack/router-generator@1.167.6
- @tanstack/router-plugin@1.168.7
- @tanstack/router-utils@1.162.1
- @tanstack/router-vite-plugin@1.167.7
- @tanstack/solid-router@1.170.5
- @tanstack/solid-start@1.168.7
- @tanstack/solid-start-client@1.168.0
- @tanstack/solid-start-server@1.167.5
- @tanstack/start-client-core@1.170.0
- @tanstack/start-plugin-core@1.171.0
- @tanstack/start-server-core@1.169.0
- @tanstack/start-static-server-functions@1.167.5
- @tanstack/start-storage-context@1.167.5
- @tanstack/vue-router@1.170.5
- @tanstack/vue-start@1.168.7
- @tanstack/vue-start-client@1.167.5
- @tanstack/vue-start-server@1.167.5
@tanstack/start-static-server-functions@1.167.5
- Updated dependencies [
5fa9e55]:- @tanstack/start-client-core@1.170.0
- @tanstack/react-start@1.168.7
- @tanstack/solid-start@1.168.7
@tanstack/vue-start-server@1.167.5
- Updated dependencies [
5fa9e55]:- @tanstack/start-client-core@1.170.0
- @tanstack/start-server-core@1.169.0
- @tanstack/router-core@1.171.3
- @tanstack/vue-router@1.170.5
@tanstack/vue-start-client@1.167.5
- Updated dependencies [
5fa9e55]:- @tanstack/start-client-core@1.170.0
- @tanstack/router-core@1.171.3
- @tanstack/vue-router@1.170.5
@tanstack/start-storage-context@1.167.5
- Updated dependencies [
5fa9e55]:- @tanstack/router-core@1.171.3
@tanstack/start-server-core@1.169.0
-
Add deferred Hydrate boundary support for TanStack Start. (#7362)
Hydrate boundaries can now be code-split by the Start compiler, preload their generated client chunks, preserve server-rendered fallback HTML, and replay interaction-triggered events after hydration. The compiler integration now uses a Start-owned compiler plugin for Hydrate virtual modules across Vite and Rsbuild, with dev invalidation for generated virtual modules.
Shared AST utilities used by the router code-splitter and Hydrate virtual modules were moved into
@tanstack/router-utilsso both pipelines can retain referenced top-level declarations, unwrap local exports, and let dead-code elimination remove unused route module code.
- Updated dependencies [
5fa9e55]:- @tanstack/start-client-core@1.170.0
- @tanstack/router-core@1.171.3
- @tanstack/start-storage-context@1.167.5