Highlights
Import Attributes type: 'text'
Rsbuild now supports the import attributes syntax with { type: 'text' } for importing file contents as source text:
import rawCSS from './example.css' with { type: 'text' };This aligns with the TC39 Import Text proposal.
What's Changed
New Features 🎉
- feat(core): add strict-port CLI option by @chenjiahan in #8029
- feat(core): track native config dependencies by @chenjiahan in #8030
- feat(core): support custom argv in runCLI by @chenjiahan in #8032
- feat(core): add loadConfig command option by @chenjiahan in #8033
- feat(core): support Helium browser by @zalishchuk in #8034
- feat(core): export config definition types by @chenjiahan in #8036
- feat(core): support text import attributes for scripts by @chenjiahan in #8037
- feat(core): support CSS text import attributes by @chenjiahan in #8042
- feat(core): support custom config file names by @chenjiahan in #8043
- feat(core): support asset text import attributes by @chenjiahan in #8046
- feat(plugin-svgr): support SVG text import attributes by @chenjiahan in #8047
- feat(core): support text import attributes for JSON by @chenjiahan in #8051
Bug Fixes 🐞
- fix(core): parse command after global options by @chenjiahan in #8035
- fix(plugin-babel): skip text import attributes in standalone rule by @chenjiahan in #8039
- fix(plugin-babel): skip raw query in standalone rule by @chenjiahan in #8040
- fix(plugin-babel): skip URL dependencies in standalone rule by @chenjiahan in #8041
- fix(core): print gzip size for script assets by @chenjiahan in #8052
Document 📖
- docs: clarify negated CLI flags by @chenjiahan in #8028
- docs(website): add react compiler rust version use into rsbuild by @WuMingDao in #8031
- docs: update React Compiler guides by @chenjiahan in #8038
- docs: update e2e testing guidance by @chenjiahan in #8045
Other Changes
- chore(skills): update release core skill by @chenjiahan in #8024
- chore(deps): update dependency node to v24.17.0 by @renovate in #8025
- chore(deps): update actions/checkout action to v7 by @renovate in #8026
- test: add dead code elimination e2e case by @chenjiahan in #8027
- release: @rsbuild/plugin-babel v2.0.1 by @chenjiahan in #8044
- release: @rsbuild/plugin-sass v2.0.1 by @chenjiahan in #8048
- release: @rsbuild/plugin-less v2.0.1 by @chenjiahan in #8049
- release: @rsbuild/plugin-svgr v2.0.5 by @chenjiahan in #8050
- release: v2.1.3 by @chenjiahan in #8054
Full Changelog: v2.1.2...v2.1.3