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
docs(new): add TSDoc comments to the Frame class #5995
Conversation
@@ -360,6 +360,80 @@ export class FrameManager extends EventEmitter { | |||
} | |||
} | |||
|
|||
/** | |||
* At every point of time, page exposes its current frame tree via the [page.mainFrame()](#pagemainframe) and [frame.childFrames()](#framechildframes) methods. |
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.
Usage of the
is a bit inconsistent. Here page
is described without the
in front of it. But on line 367 it's the page
.
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.
you'll need to swap the links for the @link
syntax that TSDoc uses: https://api-extractor.com/pages/tsdoc/tag_link/
* [Frame] object's lifecycle is controlled by three events, dispatched on the page object: | ||
* - ['frameattached'](#event-frameattached) - fired when the frame gets attached to the page. A Frame can be attached to the page only once. | ||
* - ['framenavigated'](#event-framenavigated) - fired when the frame commits navigation to a different URL. | ||
* - ['framedetached'](#event-framedetached) - fired when the frame gets detached from the page. A Frame can be detached from the page only once. |
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.
Once these are documented on the Page
class we can link to them but we won't be able to yet - so maybe just make these:
. framedetached
- fires when the ...
* console.log(text); | ||
* ``` | ||
* | ||
* @public |
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 looks great - I think you'll want to use @remarks
to split a summary from the full description: https://api-extractor.com/pages/tsdoc/tag_remarks/
@kaycebasques definitely on the right track :) Thank you! |
@kaycebasques hey, do you have any time soon to finish this off? Doesn't matter at all, I'm very happy to do the final tidying up and merge it, but don't want to if you're planning to :) |
#6188 picks this up and adds docs for all the frame methods, building off this start. Thanks @kaycebasques :) |
@jackfranklin || @mathiasbynens please let me know if I'm on the right track