fix: tiktok puppeteer waitUntil (#10713)

* fix: tiktok puppeteer waitUntil

* fix: use `networkidle2` instead

ref: https://github.com/puppeteer/puppeteer/issues/1552#issuecomment-350954419
This commit is contained in:
DIYgod 2022-09-06 11:15:59 +01:00 committed by GitHub
parent 260a3887a8
commit 38aa2eb4ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ module.exports = async (ctx) => {
request.resourceType() === 'document' || request.resourceType() === 'script' ? request.continue() : request.abort();
});
await page.goto(`${baseUrl}/${user}`, {
waitUntil: 'domcontentloaded',
waitUntil: 'networkidle2',
});
const SIGI_STATE = await page.evaluate(() => window.SIGI_STATE);
browser.close();