Skip to content

v2.3.4

Latest

Choose a tag to compare

@intellild intellild released this 24 Nov 07:58
· 6 commits to main since this release

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 🎉

  • feat: support output.environment.spread by @hai-x in #16604
  • feat: show plugin names in SRI and ESM library diagnostics by @chenjiahan in #16728
  • feat: show plugin names in copy errors and ESM chunk name warnings by @chenjiahan in #16731
  • feat: show loader names in SWC and Lightning CSS warnings by @chenjiahan in #16732
  • feat(runtime): bridge webpack runtime globals for runtime extensions by @LingyuCoder in #16681
  • feat: show source filenames in asset conflict errors by @chenjiahan in #16733
  • feat: support output.environment.symbol by @hai-x in #16707
  • feat(create-rspack): add Solid JavaScript and TypeScript templates by @chenjiahan in #16752
  • feat(javascript): clarify warnings for dynamic module paths by @chenjiahan in #16771
  • feat(lightningcss): add lightDark feature option by @CyberAP in #16829
  • feat(lightningcss): support drafts.scrollNavigationControls by @chenjiahan in #16833

Performance 🚀

Bug Fixes 🐞

  • fix(cache): validate virtual modules by content in new cache by @ahabhgk in #16679
  • fix: tree shake shorthand property in destructuring assignment by @hai-x in #16659
  • fix(ci): handle nightly Rust linker flags in musl builds by @stormslowly in #16696
  • fix(deps): upgrade SWC to fix preserved class name collisions by @chenjiahan in #16697
  • fix: make warning regex filters stateless by @ragib-mrb in #16694
  • fix(rsc): preserve CSS import order in RSC entries by @SyMind in #16699
  • fix(rsc): preserve client module order in RSC entries by @SyMind in #16704
  • fix(rsc): reuse generated entries from the persistent cache by @ahabhgk in #16709
  • fix(mf): isolate shared fallback caches and outputs by @ahabhgk in #16721
  • fix(javascript): avoid numeric-only chunk content hashes by @hai-x in #16715
  • fix: restore source map extraction warnings from module cache by @ahabhgk in #16723
  • fix(cache): preserve cacheability for handled importModule errors by @ahabhgk in #16727
  • fix(css): preserve pure context in nested rules by @intellild in #16685
  • fix(mf): match short caret and tilde ranges in the consume runtime by @arnaud-zg in #16663
  • fix(core): stop module graph memory growth in watch mode by @Dennis273 in #16475
  • fix(html): include the filename in HTML parse errors by @chenjiahan in #16737
  • fix(asset): clarify the error for unknown MIME types by @chenjiahan in #16741
  • fix(core): show the resolution directory in missing loader errors by @chenjiahan in #16744
  • fix(core): distinguish source map read and parse failures by @chenjiahan in #16746
  • fix(define-plugin): clarify conflicting NODE_ENV values by @chenjiahan in #16747
  • fix(core): preserve query and fragment in fully specified import hints by @chenjiahan in #16756
  • fix(core): skip file extension hints when resolving directories by @chenjiahan in #16757
  • fix(runtime): honor even priorities in onChunksLoaded by @chenjiahan in #16758
  • fix(core): shorten long lists of possible exports by @chenjiahan in #16762
  • fix(worker): treat top-level this in classic browser worker entry as global scope by @JSerFeng in #16763
  • fix: iterate ArrayQueue in FIFO order after internal reversal by @ragib-mrb in #16787
  • fix(deps): upgrade swc_core to 85.0.0 to keep React Compiler source maps by @Nsttt in #16775
  • fix(core): clarify the hint for fully specified imports by @chenjiahan in #16788
  • fix: clamp unit index and reject non-finite values in formatSize by @ragib-mrb in #16789
  • fix: return false in Template.getModulesArrayBounds for empty or invalid module ids by @ragib-mrb in #16790
  • fix: reject out-of-range version components in encodeVersion by @ragib-mrb in #16791
  • fix: honor boolean stats options and aggregate versions by @ragib-mrb in #16726
  • fix(rsc): unblock compiler shutdown after a fatal build error by @SyMind in #16818
  • fix(css): resolve imported @value class selectors to the shared scope… by @intellild in #16740
  • fix: tree shake evaluation-only dynamic imports by @SyMind in #16738
  • fix(css): inject external @import rules with exportType style by @intellild in #16734
  • fix(css): preserve inherited conditions and intersect media queries for external @import by @intellild in #16759
  • fix(cache): honor virtual module writes in thisCompilation by @ahabhgk in #16820
  • fix(rsc): include client references returned by server actions by @SyMind in #16821
  • fix(cache): avoid producer dependencies on extracted CSS modules by @ahabhgk in #16825
  • fix(cache): respect force_build when restoring modules from cache by @ahabhgk in #16826
  • fix: compile error by @hai-x in #16828
  • fix(tree-shaking): track short-circuit dependency guards by @LingyuCoder in #16816
  • fix(javascript): clarify invalid DefinePlugin expression warnings by @chenjiahan in #16794
  • fix: normalize absolute source map resource paths by @SyMind in #16778

Refactor 🔨

  • refactor(hmr): resolve loading chunk data in the assign runtime ids pass by @hai-x in #16710
  • refactor: avoid redundant work in source map extraction by @ahabhgk in #16736
  • refactor(core): share module options by matched rule effects by @ahabhgk in #16743
  • refactor(watcher): store timestamps and event baselines in one file record by @stormslowly in #16824

Document 📖

Other Changes

New Contributors

Full Changelog: v2.3.3...v2.3.4