-
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
doc(cli): list valid categories #9399
doc(cli): list valid categories #9399
Conversation
readme.md
Outdated
@@ -113,6 +113,8 @@ Examples: | |||
lighthouse <url> --quiet --chrome-flags="--headless" Launch Headless Chrome, turn off logging | |||
lighthouse <url> --extra-headers "{\"Cookie\":\"monster=blue\"}" Stringify\'d JSON HTTP Header key/value pairs to send in requests | |||
lighthouse <url> --extra-headers=./path/to/file.json Path to JSON file of HTTP Header key/value pairs to send in requests | |||
lighthouse <url> --only-categories=performance,pwa Only run specific categories. Valid categories: accessibility, | |||
best-practices, performance, pwa. |
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.
best-practices, performance, pwa. | |
best-practices, seo, performance, pwa. |
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.
Thank you, I totally overlooked "seo"!
Is there a particular reason for your suggested rder, or is it ok if I maintain alphabetical order?
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.
Added "seo" in alphabetical order.
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.
alphabetical is fine. the only other acceptable order would be the order in which the categories are rendered, but that isn't appropriate here.
b7203ea
to
dfb8635
Compare
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.
thanks for jumping in on this @olore!
readme.md
Outdated
@@ -113,6 +113,8 @@ Examples: | |||
lighthouse <url> --quiet --chrome-flags="--headless" Launch Headless Chrome, turn off logging | |||
lighthouse <url> --extra-headers "{\"Cookie\":\"monster=blue\"}" Stringify\'d JSON HTTP Header key/value pairs to send in requests | |||
lighthouse <url> --extra-headers=./path/to/file.json Path to JSON file of HTTP Header key/value pairs to send in requests | |||
lighthouse <url> --only-categories=performance,pwa Only run specific categories. Valid categories: accessibility, |
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 periodically updated from the output of lighthouse --help
do you think you could add the description to the actual cli-flags.js file itself? :)
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.
Done. Sorry I should have figured that out. Thanks for your patience.
dfb8635
to
1b5342a
Compare
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.
thanks very much @olore!
this LGTM but a few suggestions I'd want your thoughts on first
lighthouse-cli/cli-flags.js
Outdated
@@ -129,7 +129,7 @@ function getFlags(manualArgv) { | |||
'precomputed-lantern-data-path': 'Path to the file where lantern simulation data should be read from, overwriting the lantern observed estimates for RTT and server latency.', | |||
'lantern-data-output-path': 'Path to the file where lantern simulation data should be written to, can be used in a future run with the `precomputed-lantern-data-path` flag.', | |||
'only-audits': 'Only run the specified audits', | |||
'only-categories': 'Only run the specified categories', | |||
'only-categories': 'Only run the specified categories. Valid categories: accessibility, best-practices, performance, pwa, seo', |
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.
the only tweak I might make is
'only-categories': 'Only run the specified categories. Valid categories: accessibility, best-practices, performance, pwa, seo', | |
'only-categories': 'Only run the specified categories. Available categories: accessibility, best-practices, performance, pwa, seo', |
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.
if the user has a config that adds other categories those will be valid too, so the slightly looser Available
makes sense to me too
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.
also, sorry the example snippet you edited in the README comes from line 61 of this file if you'd want to update that description too :)
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.
yup, good call. I like this better
1b5342a
to
b67a40f
Compare
Summary
Small doc tweak to fix #9209 by listing the valid categories in an example