Skip to content

Commit

Permalink
feat: use thisCompilation in child compiler for faster builds
Browse files Browse the repository at this point in the history
  • Loading branch information
jantimon committed Jan 20, 2021
1 parent bc5697c commit 1d59e9a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/child-compiler.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ class HtmlWebpackChildCompiler {
this.compilationStartedTimestamp = new Date().getTime();
this.compilationPromise = new Promise((resolve, reject) => {
const extractedAssets = [];
childCompiler.hooks.compilation.tap('HtmlWebpackPlugin', (compilation) => {
childCompiler.hooks.thisCompilation.tap('HtmlWebpackPlugin', (compilation) => {
compilation.hooks.processAssets.tap(
{
name: 'HtmlWebpackPlugin',
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"standard-version": "9.0.0",
"style-loader": "0.23.1",
"typescript": "4.0.3",
"webpack": "5.1.0",
"webpack": "5.1.2",
"webpack-recompilation-simulator": "3.2.0"
},
"dependencies": {
Expand All @@ -58,7 +58,7 @@
"tapable": "2.0.0"
},
"peerDependencies": {
"webpack": "^5.1.0"
"webpack": "^5.1.2"
},
"keywords": [
"webpack",
Expand Down

0 comments on commit 1d59e9a

Please # to comment.