Skip to content

Commit 1d59e9a

Browse files
committed
feat: use thisCompilation in child compiler for faster builds
see also webpack/webpack#11704
1 parent bc5697c commit 1d59e9a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/child-compiler.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ class HtmlWebpackChildCompiler {
115115
this.compilationStartedTimestamp = new Date().getTime();
116116
this.compilationPromise = new Promise((resolve, reject) => {
117117
const extractedAssets = [];
118-
childCompiler.hooks.compilation.tap('HtmlWebpackPlugin', (compilation) => {
118+
childCompiler.hooks.thisCompilation.tap('HtmlWebpackPlugin', (compilation) => {
119119
compilation.hooks.processAssets.tap(
120120
{
121121
name: 'HtmlWebpackPlugin',

package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"standard-version": "9.0.0",
4747
"style-loader": "0.23.1",
4848
"typescript": "4.0.3",
49-
"webpack": "5.1.0",
49+
"webpack": "5.1.2",
5050
"webpack-recompilation-simulator": "3.2.0"
5151
},
5252
"dependencies": {
@@ -58,7 +58,7 @@
5858
"tapable": "2.0.0"
5959
},
6060
"peerDependencies": {
61-
"webpack": "^5.1.0"
61+
"webpack": "^5.1.2"
6262
},
6363
"keywords": [
6464
"webpack",

0 commit comments

Comments
 (0)