From 60007d8e3c01436613901791d7e5176d73663a2f Mon Sep 17 00:00:00 2001 From: "greenkeeper[bot]" Date: Mon, 20 May 2019 10:28:07 +0000 Subject: [PATCH 1/2] chore(package): update webpack to version 4.32.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 332aafd0f7..0aaaf4c8ec 100644 --- a/package.json +++ b/package.json @@ -97,7 +97,7 @@ "typescript": "^3.4.5", "url-polyfill": "^1.1.5", "walk": "^2.3.9", - "webpack": "4.31.0", + "webpack": "4.32.0", "webpack-cli": "^3.3.2", "webpack-dev-middleware": "^3.6.2", "webpack-dev-server": "^3.3.1", From c0339f167b8cf9f05f1077b9160a8a5bade72234 Mon Sep 17 00:00:00 2001 From: Tim Schaub Date: Mon, 20 May 2019 10:33:59 -0600 Subject: [PATCH 2/2] Use mode from the loader context See https://github.com/webpack/webpack/pull/9140. --- examples/webpack/worker-loader.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/examples/webpack/worker-loader.js b/examples/webpack/worker-loader.js index cbb7b38bf7..d03e126a32 100644 --- a/examples/webpack/worker-loader.js +++ b/examples/webpack/worker-loader.js @@ -2,14 +2,7 @@ const build = require('../../tasks/serialize-workers').build; function loader() { const callback = this.async(); - - let minify = false; - - // TODO: remove when https://github.com/webpack/webpack/issues/6496 is addressed - const compilation = this._compilation; - if (compilation) { - minify = compilation.compiler.options.mode === 'production'; - } + const minify = this.mode === 'production'; build(this.resource, {minify}) .then(chunk => {