Waiting for dynamic content
Use these helper functions to wait for data:
-
page.waitFor
in Puppeteer (or Puppeteer Scraper (apify/puppeteer-scraper)). -
context.waitFor
in Web Scraper (apify/web-scraper).
Pass in time in milliseconds or a selector to wait for.
Examples:
-
await page.waitFor(10000)
- waits for 10 seconds. -
await context.waitFor('my-selector')
- waits formy-selector
to appear on the page.
For details, code examples, and advanced use cases, visit our documentation.