docs(new): migrate TimeoutError to TSDoc (#6062)

* docs(new): migrate TimeoutError to TSDoc

Co-authored-by: Alex Rudenko <alexrudenko@chromium.org>
This commit is contained in:
Alex Rudenko 2020-06-22 10:34:57 +02:00 committed by GitHub
parent ace31d6f58
commit 1cf3f06055
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 17 additions and 1 deletions

View File

@ -32,7 +32,7 @@
| [Puppeteer](./puppeteer.puppeteer.md) | The main Puppeteer class |
| [SecurityDetails](./puppeteer.securitydetails.md) | The SecurityDetails class represents the security details of a response that was received over a secure connection. |
| [Target](./puppeteer.target.md) | |
| [TimeoutError](./puppeteer.timeouterror.md) | |
| [TimeoutError](./puppeteer.timeouterror.md) | TimeoutError is emitted whenever certain operations are terminated due to timeout. |
| [Touchscreen](./puppeteer.touchscreen.md) | |
| [Tracing](./puppeteer.tracing.md) | |
| [WebWorker](./puppeteer.webworker.md) | The WebWorker class represents a [WebWorker](https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API)<!-- -->. |

View File

@ -4,6 +4,8 @@
## TimeoutError class
TimeoutError is emitted whenever certain operations are terminated due to timeout.
<b>Signature:</b>
```typescript
@ -11,3 +13,7 @@ export declare class TimeoutError extends CustomError
```
<b>Extends:</b> CustomError
## Remarks
Example operations are [page.waitForSelector](./puppeteer.page.waitforselector.md) or [puppeteer.launch](./puppeteer.puppeteer.launch.md)<!-- -->.

View File

@ -22,6 +22,16 @@ class CustomError extends Error {
}
}
/**
* TimeoutError is emitted whenever certain operations are terminated due to timeout.
*
* @remarks
*
* Example operations are {@link Page.waitForSelector | page.waitForSelector}
* or {@link Puppeteer.launch | puppeteer.launch}.
*
* @public
*/
export class TimeoutError extends CustomError {}
export type PuppeteerErrors = Record<string, typeof CustomError>;