Details about the format, quality, area and scale of the capture.

interface ImageDetails {
    format?: ImageFormat;
    quality?: number;
    rect?: _ImageDetailsRect;
    resetScrollPosition?: boolean;
    scale?: number;
}
Index
format?: ImageFormat

The format of the resulting image. Default is "jpeg".

quality?: number

When format is "jpeg", controls the quality of the resulting image. This value is ignored for PNG images. As quality is decreased, the resulting image will have more visual artifacts, and the number of bytes needed to store it will decrease.

The area of the document to capture, in CSS pixels, relative to the page. If omitted, capture the visible viewport.

resetScrollPosition?: boolean

If true, temporarily resets the scroll position of the document to 0. Only takes effect if rect is also specified.

scale?: number

The scale of the resulting image. Defaults to devicePixelRatio.