From 363723fc84f7b8477592e0105aeb331ec9a017af Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Mon, 14 Aug 2017 05:01:11 +0200 Subject: node_modules --- node_modules/webpack/lib/WebpackOptionsDefaulter.js | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'node_modules/webpack/lib/WebpackOptionsDefaulter.js') diff --git a/node_modules/webpack/lib/WebpackOptionsDefaulter.js b/node_modules/webpack/lib/WebpackOptionsDefaulter.js index 48d8d472d..24bb42321 100644 --- a/node_modules/webpack/lib/WebpackOptionsDefaulter.js +++ b/node_modules/webpack/lib/WebpackOptionsDefaulter.js @@ -28,6 +28,7 @@ class WebpackOptionsDefaulter extends OptionsDefaulter { this.set("module.wrappedContextRecursive", true); this.set("module.wrappedContextCritical", false); this.set("module.strictExportPresence", false); + this.set("module.strictThisContextOnImports", false); this.set("module.unsafeCache", true); @@ -84,6 +85,7 @@ class WebpackOptionsDefaulter extends OptionsDefaulter { this.set("resolve.unsafeCache", true); this.set("resolve.modules", ["node_modules"]); this.set("resolve.extensions", [".js", ".json"]); + this.set("resolve.mainFiles", ["index"]); this.set("resolve.aliasFields", "make", (options) => { if(options.target === "web" || options.target === "webworker") return ["browser"]; @@ -96,10 +98,17 @@ class WebpackOptionsDefaulter extends OptionsDefaulter { else return ["module", "main"]; }); + this.set("resolve.cacheWithContext", "make", (options) => { + return Array.isArray(options.resolve.plugins) && options.resolve.plugins.length > 0; + }); this.set("resolveLoader", {}); this.set("resolveLoader.unsafeCache", true); this.set("resolveLoader.mainFields", ["loader", "main"]); this.set("resolveLoader.extensions", [".js", ".json"]); + this.set("resolveLoader.mainFiles", ["index"]); + this.set("resolveLoader.cacheWithContext", "make", (options) => { + return Array.isArray(options.resolveLoader.plugins) && options.resolveLoader.plugins.length > 0; + }); } } -- cgit v1.2.3