fix: correct lighthouse result structure access
This commit is contained in:
1 parent
db992cf4fb
commit
71560b016b
1 file changed
+1
-1
@@ -20,7 +20,7 @@ function generateReport(result, outputPath) {
|
||||
}
|
||||
|
||||
function extractMetrics(result) {
|
||||
const categories = result.reportCategories;
|
||||
const categories = result.lhr?.categories || {};
|
||||
return {
|
||||
performance: categories.performance?.score * 100 || 0,
|
||||
accessibility: categories.accessibility?.score * 100 || 0,
|
||||
|
||||
Reference in new issue
Block a user