Skip to content

Commit

Permalink
Remove the explicit page viewport
Browse files Browse the repository at this point in the history
Puppeteer already uses a default viewport width of 600. Removing this,
means users can configure the viewport using the `defaultViewPort`
launch option.
  • Loading branch information
remcohaszing committed Dec 5, 2022
1 parent 5478e65 commit d2a273b
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,6 @@ const remarkMermaid: RemarkMermaid = (options) => {
page = await browser.newPage();
await page.goto(String(new URL('index.html', import.meta.url)));
await page.addScriptTag(mermaidScript);
await page.setViewport({ width: 600, height: 3000 });

results = await page.evaluate(
// We can’t calculate coverage on this function, as it’s run by Chrome, not Node.
Expand Down

0 comments on commit d2a273b

Please sign in to comment.