Highlights 💡
Support for SRI
This release introduces a new built-in SubresourceIntegrityPlugin to provide support for Subresource Integrity (SRI).
SubresourceIntegrityPlugin
is a Rust rewrite of the webpack-subresource-integrity and is much more faster.
import { experiments } from '@rspack/core';
const { SubresourceIntegrityPlugin } = experiments;
export default {
plugins: [new SubresourceIntegrityPlugin()],
output: {
crossOriginLoading: 'anonymous',
},
};
Updated Roadmap
The Rspack roadmap has been updated with new targets such as Wasm build and Rstest, see Roadmap.
What's Changed
Performance Improvements ⚡
- perf: one shot ref for class instance by @SyMind in #9267
- perf: revert opt-level to 3 by @hardfist in #9339
- perf: reuse js module between compilation by @SyMind in #9265
Exciting New Features 🎉
- feat: split chunks overall filename by @ahabhgk in #9243
- feat: chunk graph get module hash by @ahabhgk in #9242
- feat: add
--config-loader
CLI option by @krutoo in #9210 - feat: support enabling builtin loaders in compiler builder by @h-a-n-a in #9262
- feat: support experiments.SubresourceIntegrityPlugin #9171 by @hardfist in #9311
- feat: supports chunkGraph and moduleGraph for cacheGroup.test by @JSerFeng in #9248
Bug Fixes 🐞
- fix: use entry arg with match resource by @ahabhgk in #9235
- fix: introduce AsyncTask, make rebuildModule safer by @JSerFeng in #9244
- fix(core): fix module external not treated as async by @hardfist in #9247
- fix(css,assets): wrong "publicPath: auto" asset path in windows by @SoonIter in #9239
- fix(deps): govern graceful-fs sourcemap phantom dependencies by @SoonIter in #9259
- fix: has async chunks by @ahabhgk in #9263
- fix: dynamic entry dependency reuse by @ahabhgk in #9268
- fix(core): add sourceURL when devtool set to 'eval-source-map' by @hardfist in #9275
- fix: persistent cache remove non-existent modules from make_failed_module by @jerrykingxyz in #9309
- fix: build cli dev failed by @LingyuCoder in #9331
- fix: asset cached source size by @ahabhgk in #9310
- fix: force load all symbol by @hardfist in #9337
- fix: initialize lazy compilation backend earlier by @chenjiahan in #9342
- fix: allow loaderContext methods to be called independently of context by @inottn in #9326
- fix: clear module_execution_results every compilation by @JSerFeng in #9346
- fix: runtime chunk check full hash by @LingyuCoder in #9355
Document Updates 📖
- docs: update Rspack roadmap by @chenjiahan in #9241
- docs: display GitHub button on homepage by @chenjiahan in #9261
- docs: update plugin compatibility status by @chenjiahan in #9276
- docs: reuse antd from
@rstack-dev/doc-ui
by @chenjiahan in #9284 - docs: config-loader CLI option by @krutoo in #9291
- docs: add
SubresourceIntegrityPlugin
by @LingyuCoder in #9302 - docs: fix Chinese comment in English docs by @sadan4 in #9316
- docs: fix letter casing of Re.Pack by @jbroma in #9344
Other Changes
- chore: release packages v1.2.3 by @ahabhgk in #9240
- chore: enable no-dts-cache by default by @hardfist in #9162
- chore(deps): update dependency memfs to v4.17.0 by @renovate in #9249
- chore(deps): update dependency postcss to ^8.5.2 by @renovate in #9250
- chore(deps): update github-actions by @renovate in #9255
- chore: fix lint-staged failed when js/ts file staged by @stormslowly in #9246
- refactor: module diagnostic action move to
Diagnosable
trait by @jerrykingxyz in #9264 - refactor: format:js should be used without args by @stormslowly in #9266
- chore(deps): update pnpm to v9.15.5 by @renovate in #9256
- chore(deps): update dependency prettier to v3.5.0 by @renovate in #9251
- test: bump pug v3 and reduce npm dependencies by @chenjiahan in #9272
- test: remove copy-webpack-plugin v5 by @chenjiahan in #9274
- chore(workflow): update version scripts and reduce dependencies by @chenjiahan in #9277
- chore: simplify ci workflow by @hardfist in #9283
- chore(deps): update dependency @swc/plugin-remove-console to ^6.2.0 by @renovate in #9292
- chore(deps): update dependency yargs to v17.7.2 - autoclosed by @renovate in #9295
- chore(deps): update dependency is-ci to v4 by @renovate in #9297
- chore(deps): update dependency husky to ^9.1.7 by @renovate in #9293
- chore(deps): update dependency wast-loader to ^1.14.1 by @renovate in #9294
- refactor: move module_argument and exports_argument to BuildInfo struct by @inottn in #9260
- chore: pin codspeed version by @hardfist in #9300
- chore: use more semantic naming profile by @hardfist in #9288
- refactor(rust): improve
replace_all_placeholder
by @shulaoda in #9289 - chore: fix bench ci by @hardfist in #9301
- chore: add codspeed badge by @hardfist in #9312
- chore: continue clean up workflow by @hardfist in #9308
- chore(deps): update dependency semver to ^7.7.1 by @renovate in #9320
- chore(deps): update dependency sass-embedded to ^1.85.0 by @renovate in #9319
- chore(deps): update dependency core-js to v3.40.0 by @renovate in #9317
- chore(deps): update dependency enhanced-resolve to v5.18.1 by @renovate in #9318
- chore(deps): update dependency serve-static to v1.16.0 [security] by @renovate in #9315
- chore(deps): update dependency cross-spawn to v7.0.5 [security] by @renovate in #9314
- revert: Revert "refactor(rust): improve
replace_all_placeholder
" by @h-a-n-a in #9304 - chore(deps): update dependency vitest to v3 by @renovate in #9298
- refactor: rename Rspack to JsCompiler by @hardfist in #9327
- chore(deps): update rspress to v1.41.2 by @renovate in #9328
- chore(deps): update dependency terser to v5.39.0 by @renovate in #9329
- chore: remove justfile by @hardfist in #9332
- ci: cargo shear not found by @LingyuCoder in #9334
- refactor: NormalModule.source remove diagnostic data by @jerrykingxyz in #9281
- chore: run bench using release profile by @hardfist in #9338
- chore(deps): update dependency fastify-graceful-shutdown to v4 by @renovate in #9330
- chore(deps): update dependency date-fns to v4 by @renovate in #9351
- chore(deps): update dependency @monaco-editor/react to ^4.7.0 by @renovate in #9349
- chore(deps): update dependency markdown-to-jsx to ^7.7.4 by @renovate in #9350
- chore: update webpack 5.97.1 by @stormslowly in #9340
- chore: add tests option by @hardfist in #9361
New Contributors
- @krutoo made their first contribution in #9210
- @sadan4 made their first contribution in #9316
- @jbroma made their first contribution in #9344
Full Changelog: v1.2.3...v1.2.4