Closed Nithanaroy closed 3 years ago
Thanks a lot Rick and sorry for the last minute submission.
performance
key appear? httparchive.pages
?How does WPT know to run this new file? I got some hints from the Makefile but just curios to know how this repo works.
WPT runs all files under the custom_metrics
directory that end in *.js
And where does this new performance key appear? httparchive.pages?
That's right. In the pages
JSON blob there will be a top-level property for each custom metric.
Rick, assuming this is the only metric in performance, we could have directly returned the value getLcpElement()
right? That is Promise.all([])
was mainly created for future proofing the schema right?
// [performance]
function getLcpElement() {
return new Promise((resolve) => {
...
}
return getLcpElement()
Exactly
Progress on https://github.com/HTTPArchive/almanac.httparchive.org/issues/2148
https://www.webpagetest.org/jsonResult.php?test=210630_AiDcW5_45f47b83f50f2cfd80d460827d845164&pretty=1 is the test result JSON with
lcp_stats
as the custom metric.