-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
core(viewport): create ViewportMeta computed artifact #7264
Conversation
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.
LGTM!
just some naming comments
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.
Looks good! My comments are really just style/nits.
The computed artifact needs tests, though. I'd imagine most of the computed/viewport-meta-test.js
tests will be what's in viewport-test.js
now (plus any other coverage you think we need), so hopefully it'll be painless.
Thanks for the feedback @patrickhulce and @brendankenny!
Moved most of the tests over to |
heh, I specifically didn't make the test comment because in refactoring PRs I like to see that the original case and flowthrough works exactly as it used it :) buuuuuut, since @brendankenny pointed it out, I say yes 👍 |
Missed a |
@brendankenny What do you think of the PR now? |
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.
LGTM2! 📱🖥🖼📐
Summary
Get the viewport info from a ViewportMeta computed artifact, instead of the font size and tap target audits calling the viewport audit.
Involves making the three audits involved async because computed artifacts are async.
@brendankenny also mentioned including a
notApplicable
property in the artifact result, for when Lighthouse is run in desktop mode. I've not done that for now, but will consider it when adding theisMobile
artifact or addingnotApplicable
logic to tap targets.Related Issues/PRs
Closes #7084