2023-01-18 14:06:20 +00:00
|
|
|
---
|
|
|
|
sidebar_label: Page.screenshot_1
|
|
|
|
---
|
|
|
|
|
|
|
|
# Page.screenshot() method
|
|
|
|
|
|
|
|
#### Signature:
|
|
|
|
|
|
|
|
```typescript
|
|
|
|
class Page {
|
|
|
|
screenshot(
|
|
|
|
options?: ScreenshotOptions & {
|
|
|
|
encoding?: 'binary';
|
|
|
|
}
|
|
|
|
): Promise<Buffer>;
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
## Parameters
|
|
|
|
|
2023-02-23 12:31:23 +00:00
|
|
|
| Parameter | Type | Description |
|
|
|
|
| --------- | ------------------------------------------------------------------------------------ | ------------ |
|
|
|
|
| options | [ScreenshotOptions](./puppeteer.screenshotoptions.md) & { encoding?: 'binary'; } | _(Optional)_ |
|
2023-01-18 14:06:20 +00:00
|
|
|
|
|
|
|
**Returns:**
|
|
|
|
|
|
|
|
Promise<Buffer>
|