Created
January 18, 2019 13:44
-
-
Save sibelius/baf12454c371e9d6c728376c39d9f1e0 to your computer and use it in GitHub Desktop.
Webpack 4.23.0 patch to make import eager instead of lazy to make wp4 development mode faster
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
patch-package | |
--- a/node_modules/webpack/lib/dependencies/ImportParserPlugin.js | |
+++ b/node_modules/webpack/lib/dependencies/ImportParserPlugin.js | |
@@ -28,7 +28,8 @@ class ImportParserPlugin { | |
const param = parser.evaluateExpression(expr.arguments[0]); | |
let chunkName = null; | |
- let mode = "lazy"; | |
+ // let mode = "lazy"; | |
+ let mode = "eager"; | |
let include = null; | |
let exclude = null; | |
const groupOptions = {}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
this will backport this PR webpack/webpack#8645 to webpack 4
You should only apply this patch in development mode, not in production
npx patch-package
to apply the patch