-
Notifications
You must be signed in to change notification settings - Fork 9.5k
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
Gatherer/artifact cleanup #6747
Comments
|
I like the standardization on |
Is this issue comprehensive with what we're wanting to accomplish with artifact cleanup, or are there more that need to be tended to? If it's not the full list, then can Connor take on fleshing it out? |
I think the primary goal is getting our artifacts in a state ready and useful for plugins. If someone wants to do some brainstorming what audits might need to know about a page and how we should standardize it, that'd be super useful :) |
OK decision time and input needed! Over in #8133 (comment) we were discussing exposing the DevTools-style child-index path on the My proposal is we only expose Most of the artifacts were written for specific audits in mind and by exposing them to arbitrary usage I think we run the risk of folks accidentally using the wrong thing or in a way we didn't intend and coming up with wrong results and/or stuck supporting a use case we never wanted to support. This is somewhat similar policy to the devtools protocol methods, making our BaseArtifacts + Element artifacts our "v1 stable" protocol. In addition, I think certain properties on our elements should become "private". For example, the only purpose of the devtools-specific child-index node path is for node revealing, so until we support plugins in Devtools (feels a ways off), there is no need to expose that under a generic property name of Thoughts on this proposal? Any objections? lighthouse/types/artifacts.d.ts Lines 21 to 48 in b374ea4
|
This is more or less done for 5.0 in See the number of links above for PRs where this was done and plugins.md#available-artifacts for developer information on using the artifacts. |
In a plugin world, the gatherers become part of our public API. We know about a few things we're interested in changing. Let's capture them here.
MetaElements
gatherer which gets name/content of all of them. This would nullify the following:ThemeColor
,Viewport
,MetaRobots
,MetaDescription
, (core(meta): refactor all meta audits to single artifact #7025)LinkElements
gatherer (..actually introduced in core(preconnect): add warning if preconnect link is not used #6694 asExternalResourceLinks
). This could nullifyCanonical
andHreflang
(core(canonical): move canonical audit to LinkElements #7080)AnchorElements
gatherer which gets rel/href/target/text of alla
elements, nullifiesAnchorsWithNoRelNoopener
andCrawlableLinks
(core(artifacts): unify AnchorElements into single gatherer #7101)ImageUsage
intoImageElements
gatherer (core(images): cleanup ImageUsage to match other *Elements artifacts #7030)Scripts
intoScriptElements
gatherer (core(scripts): move to ScriptElements artifact #7920)@patrickhulce you had a few in mind, too, right?The text was updated successfully, but these errors were encountered: