Skip to content
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

chore: generate docs for the protocol #6213

Merged
merged 1 commit into from Jul 13, 2020

Conversation

jackfranklin
Copy link
Collaborator

@jackfranklin jackfranklin commented Jul 13, 2020

The motivation here is that in our code we often say a function takes an argument that is of type Protocol.X.

We then have some options for how we document this well:

  • Link the user to the devtools protocol viewer
  • Duplicate the possible values in the TSDoc comment
  • Leave the user to figure this out.

None of these are great options, so instead what we can do is tell API Extractor to generate API docs for the devtools-protocol package. This means if we have function x(someArg: Protocol.Y) the docs will generate a link on Protocol.X that the user can click to be taken to documentation for that part of the protocol.

We can improve the situation further with some small tweaks to the devtools protocol generator to make the outputted comments TSDoc compliant (I will be doing that today) but this PR just dumps in the generated documentation (there's quite a lot!.

Copy link
Member

@mathiasbynens mathiasbynens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I carefully reviewed every single li—

Rubberstamp LGTM

@jackfranklin jackfranklin force-pushed the generate-docs-for-devtools-protocol branch from 2fb3389 to e078bb7 Compare July 13, 2020 12:44
@jackfranklin jackfranklin merged commit 3effcaf into main Jul 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants