Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow waitFor* actions when rendering. #89

Closed
mjpieters opened this issue Mar 4, 2018 · 2 comments
Closed

Allow waitFor* actions when rendering. #89

mjpieters opened this issue Mar 4, 2018 · 2 comments

Comments

@mjpieters
Copy link

mjpieters commented Mar 4, 2018

When rendering a page, you sometimes need to wait for AJAX requests to complete. While using a sleep time can help, that method will easily fail if the network is slow or congested. Either expose the Pyppeteer page object or allow the caller to specify some waitFor* configuration.

For example, waitForNavigation() lets you specify a specific event to wait for, like networkidle0, which usually indicates all network-dependent JS code is done.

@kennethreitz
Copy link
Collaborator

@kennethreitz
Copy link
Collaborator

in master, you can now access the r.html.page attribute after running r.html.render().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants