Skip to content

Commit

Permalink
fix: Generates screenshots with captureBeyondViewport disabled
Browse files Browse the repository at this point in the history
Puppeteer V7 introduced a breaking change on how ViewPort is handled.

Since this change, page.screenshot() now captures using Clip dimensions
instead of ViewPort size

To come back to old behavior `captureBeyondViewport` should be set to
`false`

See: https://github.com/puppeteer/puppeteer/releases/tag/v7.0.0
  • Loading branch information
Ldoppea committed Jul 12, 2021
1 parent a8b8aa0 commit 48d1178
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scripts/screenshots.js
Expand Up @@ -55,7 +55,8 @@ const screenshotComponent = async (page, options) => {
screenshotDir,
getScreenshotName({ component, viewport, suffix })
),
fullPage: true
fullPage: true,
captureBeyondViewport: false
})
}

Expand Down

0 comments on commit 48d1178

Please sign in to comment.