We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 018c3c8 commit 6962eabCopy full SHA for 6962eab
api/_lib/puppeteer.ts
@@ -19,9 +19,8 @@ async function getPage() {
19
export async function getScreenshot(url, width, height) {
20
const page = await getPage();
21
await page.setViewport({ width: Number(width) || 1280, height: Number(height) || 720, deviceScaleFactor: 2 });
22
- await page.goto(url, {
23
- waitUntil: 'domcontentloaded',
24
- });
+ await page.goto(url);
+ await new Promise(r => setTimeout(r, 3000));
25
const file = await page.screenshot();
26
return file;
27
}
0 commit comments