TTFB and MP-FID missing in debug metrics output
Feature request summary
TTFB and MP-FID don't seem be available in the debug metrics for easy tracking. Is there a good way to capture those aside from (awkwardly) parsing the strings from their audits?
We would ideally want these metrics to be available under lighthouseResult.audits.metrics.details.items[0].
What is the motivation or use case for changing this?
Not including these metrics might have just been an oversight. It will make usability of this a lot easier as opposed to having to parse strings from elsewhere.
How is this beneficial to Lighthouse?
Makes lighthouse results more usable and automatable
Is there a good way to capture those aside from (awkwardly) parsing the strings from their audits?
Yes, all these audits have a numericValue property which is a number and not a string.
lighthouseResult.audits['max-potential-fid'].numericValue
lighthouseResult.audits['time-to-first-byte'].numericValue
We should probably still include them in metrics details though :)
Thanks so much for the quick response. Will parse the docs and values and will reach out if there are any more questions.
Trying to run this, I don't see a "numericValue" field.
https://www.googleapis.com/pagespeedonline/v5/runPagespeed?url=https://www.google.com
Is there a special flag I need to pass to get this to show up?
Ah, for the PSI API, I think it wasn't exposed in the API response, but it should be very soon
@exterkamp
It's staged now, to promote soon 😄
Sorry for the delay 😓
Ty for the super quick turnaround!
Forgot to circle back to this ticket! This is fixed now :wrench: