Skip to content

Releases: web-infra-dev/rspack

v1.0.3

04 Sep 15:45
Compare
Choose a tag to compare

What's Changed

Performance Improvements ⚑

Exciting New Features πŸŽ‰

Bug Fixes 🐞

Document Updates πŸ“–

Other Changes

  • chore(deps): bump actions/download-artifact from 3 to 4.1.7 in /.github/workflows by @dependabot in #7783
  • chore: cleanup unused module syntax by @ahabhgk in #7790

Full Changelog: v1.0.2...v1.0.3

v1.0.2

04 Sep 03:38
Compare
Choose a tag to compare

What's Changed

Performance Improvements ⚑

Bug Fixes 🐞

Document Updates πŸ“–

Other Changes

New Contributors

Full Changelog: v1.0.1...v1.0.2

v1.0.1

03 Sep 11:05
Compare
Choose a tag to compare

πŸ’‘ Highlights

Improved create-rspack

Support for the addition of Biome / ESLint / Prettier when creating a new Rspack project:

create-rspack

Improve error logs of serde deserialize error

  • before:
    image

  • after:
    image

What's Changed

Performance Improvements ⚑

Exciting New Features πŸŽ‰

Bug Fixes 🐞

  • fix: use topological order when SideEffectsFlagPlugin optimize incoming connections by @ahabhgk in #7717
  • fix(core): improve error report when load builtin:swc-loader and buitin:lightningcss-loader by @hardfist in #7700
  • fix: align ignored module debug comment with webpack by @fi3ework in #7736
  • fix: template react logo animation css selector by @velusgautam in #7741
  • fix: add in_function_scope for getters and setters by @CPunisher in #7745

Document Updates πŸ“–

Other Changes

New Contributors

Full Changelog: v1.0.0...v1.0.1

v1.0.0

28 Aug 04:50
Compare
Choose a tag to compare

image

See Announcing Rspack 1.0 for more details πŸŽ‰

What's Changed

Breaking Changes πŸ› 

  • fix: compilation errors and warnings should be RspackError by @h-a-n-a in #6900
  • feat: deprecate JavaScript API by @h-a-n-a in #6859
  • feat: upgrade swc to latest version by @hardfist in #6887
  • refactor: remove profile integration timestamp by @LingyuCoder in #6947
  • feat: remove fields of SwcJsMinimizerRspackPluginOptions by @h-a-n-a in #6950
  • fix!: align optimization.moduleIds and optimization.chunkIds when mode=none by @LingyuCoder in #6956
  • feat!: remove output.amdContainer from config by @fi3ework in #6958
  • feat!: revert default values of SwcJsMinimizer by @h-a-n-a in #6970
  • fix!: set default value of concatenateModules to true in production mode by @JSerFeng in #6959
  • refactor!: use swc_plugin_prefresh instead of builtin swc plugin by @LingyuCoder in #7069
  • feat!: detect conflicting values in DefinePlugin by @h-a-n-a in #7045
  • feat!: remove builtins.provide by @h-a-n-a in #7086
  • feat!: use native resolver in loader by @bvanjoi in #4945
  • fix!: correct names of hash fields in asset.info by @xc2 in #7220
  • feat(deps)!: updatewebpack-dev-server to v5 and no longer lock the versions by @SoonIter in #7130
  • fix!: remove @rspack/plugin-minify by @hardfist in #7307
  • feat!(crates): upgrade swc_core to 0.99.5 by @LingyuCoder in #7292
  • feat!: improve HtmlRspackPlugin by @LingyuCoder in #7577
  • refactor!: disable css minify in html minify and remove SwcCssMinimizerRspackPlugin by @ahabhgk in #7547
  • feat!: support optimization.emitOnErrors by @LingyuCoder in #7595
  • feat(core)!: change dojang default escape|unescape to lodash.template syntax by @hardfist in #7661

Performance Improvements ⚑

Exciting New Features πŸŽ‰

Read more

v1.0.0-rc.2

27 Aug 15:03
Compare
Choose a tag to compare

What's Changed

Exciting New Features πŸŽ‰

  • feat: apply affected modules to all cgm phase by @ahabhgk in #7684
  • feat: apply affected modules for provide exports by @ahabhgk in #7703
  • feat: support "loose-unrecognized-keys" for config validation by @h-a-n-a in #7705

Bug Fixes 🐞

Document Updates πŸ“–

Other Changes

  • revert: feat(diagnostic): improve diagnostics for swc wasm plugins by @h-a-n-a in #7690

Full Changelog: v1.0.0-rc.1...v1.0.0-rc.2

v1.0.0-rc.1

26 Aug 07:48
35cab85
Compare
Choose a tag to compare

What's Changed

Exciting New Features πŸŽ‰

Bug Fixes 🐞

Document Updates πŸ“–

Other Changes

  • refactor: use trait for dependencyConditionFn for better cacheable by @JSerFeng in #7679

Full Changelog: v1.0.0-rc.0...v1.0.0-rc.1

v1.0.0-rc.0

23 Aug 07:18
621cd3b
Compare
Choose a tag to compare

πŸ’‘ Highlights

Faster eval-source-map

eval-source-map is now 80% faster than the previous version, see #7630.

image

HtmlRspackPlugin Escape Syntax

Now HtmlRspackPlugin uses the same syntax as html-webpack-plugin to escape a value. This can help you migrate from html-webpack-plugin to HtmlRspackPlugin more smoothly.

  • Before: Use <%= to escape the value, <%- does not escape the value.
  • After: Use <%- to escape the value, <%= does not escape the value.

For example, if a template value is <div>Rspack</div>, the current output will be:

<!-- Input -->
<%= value %>
<%- value %>

<!-- Output -->
<div>Rspack</div>
&lt;div&gt;Rspack&lt;/div&gt

PR: #7661

What's Changed

Breaking Changes πŸ› 

  • feat!: support optimization.emitOnErrors by @LingyuCoder in #7595
  • feat(core)!: change dojang default escape|unescape to lodash.template syntax by @hardfist in #7661

Performance Improvements ⚑

Exciting New Features πŸŽ‰

Bug Fixes 🐞

  • fix(node-stuff): use more conventional shim method by @fi3ework in #7587
  • fix: missing compiler.inputFileSystem type by @chenjiahan in #7597
  • fix: should not panic if provide dependency is not resolved by @JSerFeng in #7609
  • fix: remove the unnecessary logic for inserting semicolons by @inottn in #7615
  • fix: allow null and undefined in EnvironmentPlugin by @colinaaa in #7617
  • fix: should not stringify loader loading requests by @h-a-n-a in #7643
  • fix(mf2): correct mf shared options by @2heal1 in #7640
  • fix: unexpected ASI generation with sequence expression by @h-a-n-a in #7650
  • fix: wrong builtin:swc-loader source maps if inputSourceMap is provided by @h-a-n-a in #7654
  • fix(html): emit error when param not found by @LingyuCoder in #7656
  • fix(mf2): initializeSharingInitTokens should be object by @2heal1 in #7657
  • fix: "module-import" simply falls back to "module" when bails by @fi3ework in #7585

Document Updates πŸ“–

  • docs: add performance bottlenecks by @chenjiahan in #7593
  • docs: keep webpack dependency in some cases by @chenjiahan in #7619
  • docs: update eslint-webpack-plugin compatible status by @9aoy in #7627
  • docs: filter rspack specific test cases by @9aoy in #7629
  • docs: migrating from rspack 0.x by @SyMind in #7625
  • docs: add notice about htmlRspackPlugin not support ejs syntax by @hardfist in #7652
  • docs: rslib link should be its github repo by @gwy15 in #7655

Other Changes

New Contributors

Full Changelog: v1.0.0-beta.5...v1.0.0-rc.0

v1.0.0-beta.5

15 Aug 14:18
5b9ef93
Compare
Choose a tag to compare

Highlights

Improved HtmlRspackPlugin

rspack.HtmlRspackPlugin has a lot of improvements to be more in line with the html-webpack-plugin.

  • [Feat] Support hash to append compilation hash
  • [Feat] Support base to inject base tag
  • [Feat] Support scriptLoading=systemjs-module
  • [Feat] Support [templatehash] in filename template, same as [contenthash]
  • [Breaking] Rename excludedChunks to excludeChunks, aligned with html-webpack-plugin
  • [Breaking] Minify html by default when mode=production
  • [Fix] No doctype parsing error
  • [Fix] Win32 relateive path
  • [Fix] Relative favicon path
  • [Fix] Wrong & escaping in script.src and link.href
  • [Test] Passed html-webpack-plugin basic cases from 45 to 85

PR: #7577

Removed SwcCssMinimizerRspackPlugin

The rspack.SwcCssMinimizerRspackPlugin has been removed to reduce binary size, please use LightningCssMinimizerRspackPlugin instead:

module.exports = {
  optimization: {
    minimizer: [
-     new rspack.SwcCssMinimizerRspackPlugin({
+     new rspack.LightningCssMinimizerRspackPlugin({
        // options
      }),
    ],
  },
};

Rspack also supports using css-minimizer-webpack-plugin.

What's Changed

Breaking Changes πŸ› 

  • feat!: improve HtmlRspackPlugin by @LingyuCoder in #7577
  • refactor!: disable css minify in html minify and remove SwcCssMinimizerRspackPlugin by @ahabhgk in #7547

Performance Improvements ⚑

Exciting New Features πŸŽ‰

  • feat: second param for loader hook by @SyMind in #7537
  • feat(create-rspack): configure Lightning CSS targets by default by @chenjiahan in #7579
  • feat(core): don't inject bundlerInfo in library mode by @hardfist in #7567
  • feat: extract-css-plugin supports layer by @JSerFeng in #7583

Bug Fixes 🐞

  • fix: use intersection runtime for concat module code gen by @ahabhgk in #7523
  • fix: chunk hash unstable by @JSerFeng in #7534
  • fix: should insert semi after import, export, debugger and class field by @CPunisher in #7529
  • fix: check SuperProp in walk_call_expression by @CPunisher in #7530
  • fix: remove useless "module" external runtime by @fi3ework in #7533
  • fix(rust-core): no need to pass resolve_factory when using rust api by @hardfist in #7539
  • fix(cli): wrong entry defaults from cli by @xc2 in #7541
  • fix: source map plugin module should enable by default by @ahabhgk in #7545
  • fix: avoid inner graph top level symbol for nested webpack_require by @ahabhgk in #7584

Document Updates πŸ“–

Other Changes

  • refactor(typescript): packages/rspack/src/node/NodeWatchFileSystem by @wxiaoyun in #7528
  • chore(infra): improve the configuration of justfile by @shulaoda in #7526
  • chore: polish some words on introduction by @hardfist in #7557
  • chore(deps): update cargo-bins/cargo-binstall action to v1.10.2 by @renovate in #7564
  • test(plugin): test html plugin with basic cases of html-webpack-plugin by @LingyuCoder in #7571
  • chore(deps): bump plugin-react-refresh and lite-tapable to v1.0.0 by @chenjiahan in #7580
  • refactor: improve esm harmony dependencies structure by @shulaoda in #7576
  • refactor: module hash by @ahabhgk in #7569

Full Changelog: v1.0.0-beta.4...v1.0.0-beta.5

v1.0.0-beta.4

10 Aug 02:11
9102876
Compare
Choose a tag to compare

What's Changed

Exciting New Features πŸŽ‰

Bug Fixes 🐞

  • fix: patch asset info in update asset by @ahabhgk in #7464
  • fix!: reuseExistingChunk should be false by default by @JSerFeng in #7489
  • fix(modern-module): export syntax detect more invalid chars by @fi3ework in #7493
  • fix: concatenation should merge module’s chunk init fragments by @fi3ework in #7504
  • fix(modern-module): correct use bailout reason by @fi3ework in #7513
  • fix: maxInitialRequests should exists in cache groups by @JSerFeng in #7512
  • fix(hmr): replacement of optionalChain is compatible with legacy versions by @wChenonly in #7510

Document Updates πŸ“–

Other Changes

New Contributors

Full Changelog: v1.0.0-beta.3...v1.0.0-beta.4

v1.0.0-beta.3

06 Aug 12:26
Compare
Choose a tag to compare

What's Changed

Breaking Changes πŸ› 

SwcJsMinimizerRspackPlugin

Move all SWC options to minimizerOptions:

  • The compress option has been moved to minimizerOptions.compress.
  • The mangle option has been moved to minimizerOptions.mangle.
  • The format option has been moved to minimizerOptions.format.
  • The module option has been moved to minimizerOptions.module.
module.exports = {
  optimization: {
    minimizer: [
      new rspack.SwcJsMinimizerRspackPlugin({
-       format: {
-         ecma: 6,
-       },
+       minimizerOptions: {
+         format: {
+           ecma: 6,
+         },
+       },
      }),
    ],
  },
};

LightningCssMinimizerRspackPlugin

  • The browserslist option has been renamed to minimizerOptions.targets.
module.exports = {
  optimization: {
    minimizer: [
      new rspack.LightningCssMinimizerRspackPlugin({
-       browserslist: 'Chrome >= 53',
+       minimizerOptions: {
+         targets: 'Chrome >= 53',
+       },
      }),
    ],
  },
};

PR: #7444

Performance Improvements ⚑

  • perf: rule matcher allocates only if resource_path is not a valid UTF-8 sequence by @h-a-n-a in #7441
  • perf: bump lightningcss to remove duplicated browerslist-rs by @chenjiahan in #7461

Exciting New Features πŸŽ‰

Bug Fixes 🐞

Document Updates πŸ“–

Other Changes

  • test: enable inner graph and concat modules for runtime condition diff test by @ahabhgk in #7416
  • ci: fix git clean wrong by filename too long by @SyMind in #7425
  • chore(deps): update dependency sass-loader to v16 by @renovate in #7370
  • refactor(type): increase type-coverage by @SoonIter in #7437
  • chore(infra/biome): enable noParameterAssign by @shulaoda in #7430
  • refactor(typescript): increase typescript type coverage to 100% for rspack-plugin-react-refresh by @shulaoda in #7448
  • chore: remove log in mf test by @ahabhgk in #7451
  • chore: documentation chores, typo, format, links, etc by @AkatQuas in #7457
  • refactor!: redesign minimizer plugin options by @ahabhgk in #7444

Full Changelog: v1.0.0-beta.2...v1.0.0-beta.3