🎉 See Announcing Rspack 1.4 for more details.
What's Changed
Performance Improvements ⚡
- perf: launch background tasks immediately by @CPunisher in #10484
- perf(incremental): enable advance-slient preset by default by @ahabhgk in #10623
- perf: introduce
ModuleGraphCache
and cache the result ofget_mode
anddetermine_export_assignments
by @CPunisher in #10584 - perf: when removed files we donot need rebuild the original module by @SyMind in #10648
- perf: reduce memory allocation in
esm_export_imported_specifier_dependency
by @CPunisher in #10657 - perf: create zod schema on demand by @chenjiahan in #10669
- perf(logger): calculate trace only when needed by @chenjiahan in #10683
- perf(ci): move benchmark building to self-hosted by @stormslowly in #10680
- perf: inline module graph partials by @CPunisher in #10727
- perf: improve zod references to reduce bundle size by @chenjiahan in #10738
- perf(zod/v4): disable Zod JIT by @colinaaa in #10739
- perf: cache get exports type on module graph cache by @LingyuCoder in #10741
- perf: parallel get runtime hash of concatenated modules by @LingyuCoder in #10744
- perf: parallel get concatenated imports when enter module by @LingyuCoder in #10747
- perf: skip schema creation and parse when validation is disabled by @chenjiahan in #10768
- perf(zod): prefer to use
partial
to make all properties optional by @chenjiahan in #10778
New Features 🎉
- feat: serialized build info custom fields from js by @SyMind in #10578
- feat: rsdoctor native plugin add bailout_reason property by @easy1090 in #10585
- feat(rstest_plugin): support hoist mock and resolve mocked module id by @fi3ework in #10519
- feat: should rename default import based on source by @JSerFeng in #10598
- feat: consume js
inputFileSystem
on the rust side by @nilptr in #8643 - feat: support perfetto proto as tracing format by @hardfist in #10549
- feat: support passing error code to
callbackify
callbacks by @h-a-n-a in #10622 - feat(core): expose
StatsErrorCode
by @h-a-n-a in #10624 - feat: add d.ts in binding build artficats by @stormslowly in #10634
- feat: add swc transformSync and minifySync api by @GiveMe-A-Name in #10640
- feat: inline const for leaf modules by @ahabhgk in #10451
- feat: extend target type to include es2023, es2024, and es2025 by @chenjiahan in #10700
- feat(ci): upload perf data by commit when PR merged by @stormslowly in #10715
- feat: support preamble in swc minifier by @CPunisher in #10713
- feat(create-rspack): update tsconfig.json by @chenjiahan in #10674
- feat: add support for SHA-256 by @pgoldberg in #10553
- feat: type reexports presence tolerant by @ahabhgk in #10719
- feat(zod/v4): upgrade to Zod V4 by @colinaaa in #10678
- feat(ci): use full match only to find self-hosted build caches by @stormslowly in #10724
- feat(rstest): support manual mock by @fi3ework in #10625
- feat: introduce rspack_tasks by @hardfist in #10699
- feat: check type exports for type reexports presence tolerant by @ahabhgk in #10749
- feat: initialize Rslib built-in plugin by @fi3ework in #10735
- feat: css chunking plugin custom maxSize and minSize options by @SyMind in #10773
- feat(wasm): add simd flag by @CPunisher in #10771
- feat: typescript cross module enum inlining by @ahabhgk in #10780
Bug Fixes 🐞
- fix: correct remove_available_modules by @JSerFeng in #10594
- fix(url_plugin): return true to stop ast traverse by @nilptr in #10570
- fix: loc in rspack error should be object by @SyMind in #10610
- fix: panic when concat external module request is undefined by @ahabhgk in #10611
- fix:
number_hash
should useu64
to avoid addition overflow by @CPunisher in #10615 - fix(create-rspack): ignore rspack profile and remove npmignore file by @chenjiahan in #10616
- fix(rstest): should stringify resource path by @fi3ework in #10619
- fix: Narrow the Dev Server Middleware type by @n0th1ng-else in #10522
- fix: use
Mutex<Arc<tokio::sync::OnceCell<JsLoaderRunner>>>
to avoid loader runner deadlock by @CPunisher in #10632 - fix: change bailout_reason to array in rsdoctor native plugin by @easy1090 in #10653
- fix(schema): add
jsc.output.charset
of swc-loader by @chenjiahan in #10668 - fix: generator data url function panic by @SyMind in #10682
- fix(binding): remove Node 10 compatibility code by @chenjiahan in #10685
- fix(ci): linux x86 native build hardcoded profile by @stormslowly in #10693
- fix: failed to resolve
browserslist:env
from target by @chenjiahan in #10730 - fix: add
-debugids
to Zod schema by @colinaaa in #10728 - fix:
loaderContext.importModule
should return error by @colinaaa in #10750 - fix(rstest): put Rstest plugin in
experiments
field by @fi3ework in #10758 - fix: missing sftrace-setup feature by @SyMind in #10779
- fix: binding version check not work by @chenjiahan in #10792
- fix: remove catch for statsFactory.create by @SyMind in #10802
Refactor 🔨
- refactor: make merge modified files and removed files by @jerrykingxyz in #10662
- refactor(zod/v4): use
.superRefine()
forbuiltin:swc-loader
by @colinaaa in #10679 - refactor: js api readableIdentifier in module by @SyMind in #10686
- refactor: fast fail matrix testing to better utilizing CI runner by @stormslowly in #10687
- refactor: move codspeed build to self-hosted by @stormslowly in #10688
- refactor: prefetch exports info data of getters part 3 by @LingyuCoder in #10652
- refactor: remove unnecessary callback by @hardfist in #10714
- refactor: prefer native build for better speed by @stormslowly in #10725
- refactor(zod/v4): replace deprecated
.superRefine()
by @colinaaa in #10729 - refactor: split
rspack_node
into separaterspack_binding_api
by @h-a-n-a in #10770
Document Updates 📖
- docs: fix rsbuild command typo in tracing doc by @chenjiahan in #10612
- docs: update glossary with additional links by @chenjiahan in #10626
- docs: clarity built-in module types by @chenjiahan in #10635
- docs: add some clarification of module-graph-partial by @hardfist in #10684
- docs: use assets.rspack.dev by @stormslowly in #10692
- docs: update lazyCompilationMiddleware interface by @JSerFeng in #10695
- docs: update tracing doc typo by @hardfist in #10723
- docs: add wasm example and usage by @CPunisher in #10756
- docs: adjust incremental docs for v1.4.0 by @ahabhgk in #10769
- docs: add documentation for the new CssChunkingPlugin by @SyMind in #10766
Other Changes
- chore: release v1.3.15 by @chenjiahan in #10588
- chore(workflow): remove CI lark alerts by @chenjiahan in #10586
- chore(deps): update dependency @module-federation/runtime-tools to v0.15.0 by @renovate in #10590
- chore(deps): update patch npm dependencies by @renovate in #10589
- chore(incremental): pass more hmr test case by @ahabhgk in #10583
- chore(ci): release debug script by @stormslowly in #10580
- chore(deps): update dependency @shikijs/transformers to ^3.6.0 by @renovate in #10603
- chore(deps): update dependency terser to v5.41.0 by @renovate in #10604
- chore(deps): update dependency tinypool to ^1.1.0 by @renovate in #10605
- refactor(zod/v4): replace
z.function
withz.custom
by @colinaaa in #10602 - chore(wasm): publish wasi binding by @CPunisher in #10617
- chore(deps): update napi to 3.0.0-beta.8 by @renovate in #10562
- refactor(zod/v4): use
.superRefine()
forexternals
by @colinaaa in #10609 - chore(deps): update patch npm dependencies by @renovate in #10627
- chore: Enable sftrace for release-debug profile by @quininer in #10621
- chore(deps): update yarn to v4.9.2 by @renovate in #10628
- Revert "chore(deps): update napi to 3.0.0-beta.8" by @stormslowly in #10633
- chore(deps): update dependency @types/node to ^20.19.0 by @renovate in #10630
- chore(deps): update dependency @swc/core to v1.12.0 by @renovate in #10629
- refactor: prefetch exports info data of getters part 2 by @LingyuCoder in #10576
- chore(deps): update napi to 3.0.0-beta.8 by @stormslowly in #10637
- chore(ci): rm d.ts before move artifacts by @stormslowly in #10651
- chore: release v1.4.0-beta.0 by @h-a-n-a in #10647
- chore(wasm): cleanup useless
start/shutdownAsyncRuntime
and exports by @CPunisher in #10659 - chore(workflow): update changelog generator to include refactor label by @chenjiahan in #10656
- chore: update team members by @chenjiahan in #10667
- chore(deps): update dependency core-js to v3.43.0 by @renovate in #10665
- chore(deps): update dependency tsx to ^4.20.3 by @renovate in #10666
- chore: bump swc to 27.0.4 by @GiveMe-A-Name in #10660
- chore(deps): update dependency path-serializer to v0.5.0 by @renovate in #10671
- chore(deps): update dependency terser to v5.42.0 by @renovate in #10672
- chore(deps): update dependency zod-validation-error to v3.5.0 by @renovate in #10673
- chore(deps): update dependency @playwright/test to v1.53.0 by @renovate in #10196
- chore(wasm): publish wasi binding 2 by @CPunisher in #10645
- chore(ci): use windows self hosted by @stormslowly in #10579
- refactor!: lazy compilation middleware supports multiCompiler and use config from compiler instance by @JSerFeng in #9828
- chore: fix release-debug build for windows by @quininer in #10649
- chore: release 1.4.0-beta.1 by @CPunisher in #10681
- chore: remove rspack.dev redirect by @hardfist in #10691
- chore(workflow): simplify PR template by @chenjiahan in #10701
- chore(deps): update dependency @rslib/core to v0.10.0 by @renovate in #10703
- chore(deps): update dependency axios to ^1.10.0 by @renovate in #10705
- chore(deps): update dependency terser to v5.43.0 by @renovate in #10709
- chore(deps): update dependency ts-jest to v29.4.0 by @renovate in #10710
- chore(deps): update dependency acorn to ^8.15.0 by @renovate in #10704
- chore(benchmark): add rspack benchcases by @h-a-n-a in #9345
- chore(benchmark): limit parallel forks in vitest by @CPunisher in #10718
- chore(CI): fix codspeed build in GitHub hosted runner by @stormslowly in #10720
- chore: add diff artifact action by @CPunisher in #10731
- chore: remove prebundle config for enhanced-resolve by @chenjiahan in #10736
- chore(deps): update dependency create-rstack to v1.5.1 by @renovate in #10752
- chore(deps): update dependency rspress-plugin-sitemap to ^1.2.0 by @renovate in #10753
- ci(release): add
rc
tag by @h-a-n-a in #10761 - chore: release v1.4.0-rc.0 by @h-a-n-a in #10759
- chore: proxy extract arguments to napi as cargo options by @stormslowly in #10762
- chore: update pnpm lockfile by @h-a-n-a in #10774
- chore(workflow): integrate heading-case to format title by @chenjiahan in #10775
- chore: bump swc_core to v29.1.2 by @bvanjoi in #10772
- chore: don't measure compiler builder by @CPunisher in #10767
- chore: add
NeverGrowInPlaceAllocator
for benchmark by @CPunisher in #10781 - chore(deps): update dependency vitest to ^3.2.4 by @renovate in #10789
- chore(deps): update dependency @shikijs/transformers to ^3.7.0 by @renovate in #10786
- chore(deps): update dependency mermaid to ^11.7.0 by @renovate in #10787
- chore: bump swc by @bvanjoi in #10791
- chore(ci): including codspeed perfermance comparison into required checks by @stormslowly in #10782
- chore(deps): update napi to 3.0.0-beta.9 by @renovate in #10785
- chore(ci): fix ci workflow failed in main push event by @stormslowly in #10796
- test: fix js folder create confliction by @stormslowly in #10794
- chore: enable
fair-sched
for codspeed by @CPunisher in #10734
New Contributors
- @pgoldberg made their first contribution in #10553
Full Changelog: v1.3.15...v1.4.0