-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
misc: add cli module diagram #6129
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.
⭏⭎⭎⭏⭎⭏⭎⭏⭏
@@ -8,6 +8,19 @@ | |||
const fs = require('fs'); | |||
const path = require('path'); | |||
|
|||
/* | |||
* The relationship between these CLI modules: |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
* index.js : only calls bin.js's begin() | ||
* cli-flags.js : leverages yargs to read argv, outputs LH.CliFlags | ||
* bin.js : CLI args processing. cwd, list/print commands | ||
* run.js : chrome-launcher bits, calling lighthouse-core, output to Printer |
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.
part of me thinks the functionality here should be available from node more easily too, but that's tomorrow's problem :)
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.
agree
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.
we could turn cli/index.js
into a module and expose it that way. That would let us side step dealing with what gets included in the extension/devtools bundle and let us keep the CLI the same. Biggest issue will probably be with letting you cleanly set up cliFlags
not with a long string since we can currently assume defaults set via yargs.
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 Love the ASCII diagrams!
No description provided.