Open kangyeop opened 1 year ago
that's because the perfomance graph value is calculated as the median value of the whole performance category runs:
category_performance_median: categoryScoreMedian('performance')
while the report is the most representitve run which is the medians of FCP and TTI:
function getMedianSortValue(lhr, medianFcp, medianInteractive) {
const distanceFcp = medianFcp - getAuditValue(lhr, 'first-contentful-paint');
const distanceInteractive = medianInteractive - getAuditValue(lhr, 'interactive');
return distanceFcp * distanceFcp + distanceInteractive * distanceInteractive;
}
As shown in the image below, the dashboard and viewer scores are different. Maybe this is the spec? If it's a bug, can I fix it myself and make a PR?