Skip to main content
Module

x/puppeteer/mod.ts>ScreenshotOptions

A port of puppeteer running on Deno
Latest
interface ScreenshotOptions
Re-export
import { type ScreenshotOptions } from "https://deno.land/x/puppeteer@16.2.0/mod.ts";

Properties

optional
type: "png" | "jpeg" | "webp"
optional
path: string

The file path to save the image to. The screenshot type will be inferred from file extension. If path is a relative path, then it is resolved relative to current working directory. If no path is provided, the image won't be saved to the disk.

optional
fullPage: boolean

When true, takes a screenshot of the full page.

optional
clip: ScreenshotClip

An object which specifies the clipping region of the page.

optional
quality: number

Quality of the image, between 0-100. Not applicable to png images.

optional
omitBackground: boolean

Hides default white background and allows capturing screenshots with transparency.

optional
encoding: "base64" | "binary"

Encoding of the image.

optional
captureBeyondViewport: boolean

Capture the screenshot beyond the viewport.

optional
fromSurface: boolean

Capture the screenshot from the surface, rather than the view.