Skip to content

Commit

Permalink
optimize screenshot waitUntil
Browse files Browse the repository at this point in the history
  • Loading branch information
snowtafir committed Aug 12, 2024
1 parent 4dfd729 commit 12a8185
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/puppeteer.render.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ export class YukiPuppeteerRender extends Puppeteer {
await page.setExtraHTTPHeaders(Options.header);
}

await page.goto(`file://${htmlPath}`, { timeout: Options?.timeout ?? 120000, waitUntil: ["load", "networkidle2"] });
await page.goto(`file://${htmlPath}`, { timeout: Options?.timeout ?? 120000, waitUntil: ["load", "networkidle0"] });

const body = await page.$(Options?.tab ?? 'body')
if (!body) return false
Expand Down

0 comments on commit 12a8185

Please sign in to comment.