rubycdp / ferrum

Headless Chrome Ruby API
https://ferrum.rubycdp.com
MIT License
1.69k stars 120 forks source link

Can I allow Page.go_to take additional wait parameter? #393

Closed erickgskovik closed 10 months ago

erickgskovik commented 10 months ago

Hey,

I am working on rendering local HTML with Ferrum. During the implementation, I realize Page.go_to doesn't wait. And it might not be enough time for rendering to complete. I found FERRUM_GOTO_WAIT as a work around. It can be better to also accept wait.

Page.goto accepts an optional url. Can it also accept a wait parameter?

For the implementation details, Page.go_to accepts wait. FERRUM_GOTO_WAIT will be set if wait parameter is not set.

Another question to the details is that is there a policy to accept slowmoable? For example, for the Page.go_to.