webpack-bundle-analyzer
Advanced tools
Comparing version 4.10.1 to 4.10.2
@@ -26,3 +26,3 @@ "use strict"; | ||
const FILENAME_QUERY_REGEXP = /\?.*$/u; | ||
const FILENAME_EXTENSIONS = /\.(js|mjs)$/iu; | ||
const FILENAME_EXTENSIONS = /\.(js|mjs|cjs)$/iu; | ||
module.exports = { | ||
@@ -61,3 +61,3 @@ getViewerData, | ||
}); | ||
} // Picking only `*.js or *.mjs` assets from bundle that has non-empty `chunks` array | ||
} // Picking only `*.js, *.cjs or *.mjs` assets from bundle that has non-empty `chunks` array | ||
@@ -64,0 +64,0 @@ |
@@ -14,6 +14,2 @@ "use strict"; | ||
const { | ||
isPlainObject | ||
} = require('is-plain-object'); | ||
const { | ||
bold | ||
@@ -207,5 +203,7 @@ } = require('picocolors'); | ||
chartData = null; | ||
} | ||
} // chartData can either be an array (bundleInfo[]) or null. It can't be an plain object anyway | ||
if (isPlainObject(chartData) && Object.keys(chartData).length === 0) { | ||
if ( // analyzer.getViewerData() doesn't failed in the previous step | ||
chartData && !Array.isArray(chartData)) { | ||
logger.error("Could't find any javascript bundles in provided stats file"); | ||
@@ -219,7 +217,7 @@ chartData = null; | ||
function getEntrypoints(bundleStats) { | ||
if (bundleStats === null || bundleStats === undefined) { | ||
if (bundleStats === null || bundleStats === undefined || !bundleStats.entrypoints) { | ||
return []; | ||
} | ||
return Object.values(bundleStats.entrypoints || {}).map(entrypoint => entrypoint.name); | ||
return Object.values(bundleStats.entrypoints).map(entrypoint => entrypoint.name); | ||
} |
{ | ||
"name": "webpack-bundle-analyzer", | ||
"version": "4.10.1", | ||
"version": "4.10.2", | ||
"description": "Webpack plugin and CLI utility that represents bundle content as convenient interactive zoomable treemap", | ||
@@ -44,3 +44,2 @@ "author": "Yury Grunin <grunin.ya@ya.ru>", | ||
"html-escaper": "^2.0.2", | ||
"is-plain-object": "^5.0.0", | ||
"opener": "^1.5.2", | ||
@@ -47,0 +46,0 @@ "picocolors": "^1.0.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1233587
12
2580
- Removedis-plain-object@^5.0.0
- Removedis-plain-object@5.0.0(transitive)