From 3732a4592b2c050e766f1e78be9697b8aea85004 Mon Sep 17 00:00:00 2001 From: chenjiahan Date: Mon, 29 Apr 2024 22:03:06 +0800 Subject: [PATCH 1/2] fix: remove outdated TODOs in runtime code --- crates/rspack_plugin_hmr/src/runtime/hot_module_replacement.js | 2 -- plugin-test/css-extract/cases/hmr/expected/main.js | 2 -- 2 files changed, 4 deletions(-) diff --git a/crates/rspack_plugin_hmr/src/runtime/hot_module_replacement.js b/crates/rspack_plugin_hmr/src/runtime/hot_module_replacement.js index 7142ea78971..9dfd8037082 100644 --- a/crates/rspack_plugin_hmr/src/runtime/hot_module_replacement.js +++ b/crates/rspack_plugin_hmr/src/runtime/hot_module_replacement.js @@ -10,8 +10,6 @@ var registeredStatusHandlers = []; var currentStatus = "idle"; // while downloading -// TODO: not needed in rspack temporary, -// TODO: because we transfer all changed modules. var blockingPromises = 0; var blockingPromisesWaiting = []; diff --git a/plugin-test/css-extract/cases/hmr/expected/main.js b/plugin-test/css-extract/cases/hmr/expected/main.js index 4d44047846e..6712eb5b094 100644 --- a/plugin-test/css-extract/cases/hmr/expected/main.js +++ b/plugin-test/css-extract/cases/hmr/expected/main.js @@ -322,8 +322,6 @@ var registeredStatusHandlers = []; var currentStatus = "idle"; // while downloading -// TODO: not needed in rspack temporary, -// TODO: because we transfer all changed modules. var blockingPromises = 0; var blockingPromisesWaiting = []; From df1e8defabbe2ead60ff2115dbd1e3a7efd3be11 Mon Sep 17 00:00:00 2001 From: neverland Date: Tue, 30 Apr 2024 10:39:46 +0800 Subject: [PATCH 2/2] test: update snapshot --- .../tests/__snapshots__/StatsTestCases.test.js.snap | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/rspack-test-tools/tests/__snapshots__/StatsTestCases.test.js.snap b/packages/rspack-test-tools/tests/__snapshots__/StatsTestCases.test.js.snap index 451e3f048aa..a81068b54c6 100644 --- a/packages/rspack-test-tools/tests/__snapshots__/StatsTestCases.test.js.snap +++ b/packages/rspack-test-tools/tests/__snapshots__/StatsTestCases.test.js.snap @@ -76,11 +76,11 @@ Rspack x.x.x compiled successfully in X s (185b80456c181897fcd5)" exports[`StatsTestCases should print correct stats for hot+production 1`] = ` "PublicPath: auto -asset main.js 32.2 KiB [emitted] (name: main) -Entrypoint main 32.2 KiB = main.js +asset main.js 32.1 KiB [emitted] (name: main) +Entrypoint main 32.1 KiB = main.js runtime modules 11 modules ./index.js -Rspack x.x.x compiled successfully in X s (68e01ffb94a6b5683661)" +Rspack x.x.x compiled successfully in X s (db903683225d0fe50e7b)" `; exports[`StatsTestCases should print correct stats for ignore-plugin 1`] = `