From 7c8f0c94271c3c5e5f67256aad366244f7525d44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=96=9B=E5=AE=9A=E8=B0=94=E7=9A=84=E7=8C=AB?= Date: Mon, 22 Oct 2018 16:13:03 +0800 Subject: [PATCH] fix: disable ProvidePlugin (fixes #7032) --- lib/ProvidePlugin.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/ProvidePlugin.js b/lib/ProvidePlugin.js index b09d8c864da..3ed2fc1b4b2 100644 --- a/lib/ProvidePlugin.js +++ b/lib/ProvidePlugin.js @@ -76,9 +76,8 @@ class ProvidePlugin { normalModuleFactory.hooks.parser .for("javascript/dynamic") .tap("ProvidePlugin", handler); - normalModuleFactory.hooks.parser - .for("javascript/esm") - .tap("ProvidePlugin", handler); + + // Disable ProvidePlugin for javascript/esm, see https://github.com/webpack/webpack/issues/7032 } ); }