-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Surface Lighthouse results #4773
Conversation
co-authored by: @mxdvl co-authored by: @bryophyta
co-author: @mxdvl co-author: @bryophyta
Co-authored-by: Joshua <[email protected]> Co-authored-by: Pete Faulconbridge <[email protected]>
Actually run the deno script Co-authored-by: Joshua <[email protected]> Co-authored-by: Pete Faulconbridge <[email protected]>
Size Change: -17.4 kB (-1%) Total Size: 1.65 MB
ℹ️ View Unchanged
|
Co-authored-by: Pete Faulconbridge <[email protected]> Co-authored-by: Joshua <[email protected]>
⚡️ Lighthouse report for the changes in this PRLighthouse tested 2 URLs Report for Article
Report for Front
|
if we’re all happy with this I will squash & merge, because there’s lots of WIP commits in there. |
that's fine by me 👍 |
also update the location of the `includePassedAssertions` setting to be inside the lighthouserc.js config file
Yes I sometimes do a WIP after pairing if a task hasn't reached its endpoint but I need to sign off, so the branch can be pulled by whoever else is working on it. Big fan of squashing when I merge. |
const dir = "dotcom-rendering/.lighthouseci"; | ||
|
||
const links: Record<string, string> = JSON.parse( | ||
Deno.readTextFileSync(`${dir}/links.json`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is awesome! This will help a lot!
const getStatus = ( | ||
passed: boolean, | ||
level: AssertionResult["level"] | ||
): "✅" | "⚠️" | "❌" => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Theres something interesting about a function that has an "emoji" return type, love it!
also remove console logs
A bit cheeky, usually this would be for others’s PRs, but I’ll nominate this as a hidden gem 💎 . |
What does this change?
Surface Lighthouse results in all PRs. On merge to
main
, update the comment on #4584 to reflect the latest Lighthouse scores.The script updating the comment is powered by Deno and Github’s official
@octokit
’s libraries, as well as types from thelhci/cli
library.Why?
Closes #4584
Screenshots