Merge pull request #16144 from KurumiRin/main

fix: when the jobs parameter is an empty array, block unnecessary runCodeGenerationJobs
This commit is contained in:
Tobias Koppers 2022-11-09 10:44:30 +01:00 committed by GitHub
commit c109651dd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -3192,6 +3192,9 @@ Or do you want to use the entrypoints '${name}' and '${runtime}' independently o
}
_runCodeGenerationJobs(jobs, callback) {
if (jobs.length === 0) {
return callback();
}
let statModulesFromCache = 0;
let statModulesGenerated = 0;
const { chunkGraph, moduleGraph, dependencyTemplates, runtimeTemplate } =

View File

@ -1365,7 +1365,6 @@ asset <CLR=32,BOLD>main.js</CLR> 84 bytes <CLR=32,BOLD>[emitted]</CLR> (name: ma
<CLR=BOLD>LOG from webpack.Compilation</CLR>
<CLR=BOLD>1 modules hashed, 0 from cache (1 variants per module in average)</CLR>
<CLR=BOLD>100% code generated (1 generated, 0 from cache)</CLR>
<CLR=BOLD>NaN% code generated (0 generated, 0 from cache)</CLR>
+ 24 hidden lines
<CLR=BOLD>LOG from webpack.FlagDependencyExportsPlugin</CLR>