From 5c83dd8790e98ea1090db74d1360b1f2780e55e8 Mon Sep 17 00:00:00 2001 From: PikachuEXE Date: Thu, 23 Sep 2021 14:43:52 +0800 Subject: [PATCH] Update webpack config to remove explicit HMR plugin (#1729) This change suppresses warning " [webpack-dev-server] "hot: true" automatically applies HMR plugin, you don't have to add it manually to your webpack configuration." --- _scripts/webpack.renderer.config.js | 1 - _scripts/webpack.web.config.js | 1 - _scripts/webpack.workers.config.js | 1 - 3 files changed, 3 deletions(-) diff --git a/_scripts/webpack.renderer.config.js b/_scripts/webpack.renderer.config.js index f7b1db34..c76137c4 100644 --- a/_scripts/webpack.renderer.config.js +++ b/_scripts/webpack.renderer.config.js @@ -149,7 +149,6 @@ const config = { if (isDevMode) { // any dev only config config.plugins.push( - new webpack.HotModuleReplacementPlugin(), new webpack.DefinePlugin({ __static: `"${path.join(__dirname, '../static').replace(/\\/g, '\\\\')}"`, }) diff --git a/_scripts/webpack.web.config.js b/_scripts/webpack.web.config.js index 35e59c37..a95913d5 100644 --- a/_scripts/webpack.web.config.js +++ b/_scripts/webpack.web.config.js @@ -147,7 +147,6 @@ const config = { if (isDevMode) { // any dev only config config.plugins.push( - new webpack.HotModuleReplacementPlugin(), new webpack.DefinePlugin({ __static: `"${path.join(__dirname, '../static').replace(/\\/g, '\\\\')}"`, }) diff --git a/_scripts/webpack.workers.config.js b/_scripts/webpack.workers.config.js index 21a3ad37..d2bec27e 100644 --- a/_scripts/webpack.workers.config.js +++ b/_scripts/webpack.workers.config.js @@ -62,7 +62,6 @@ const config = { */ if (isDevMode) { // any dev only config - config.plugins.push(new webpack.HotModuleReplacementPlugin()) } else { config.plugins.push( new webpack.LoaderOptionsPlugin({