schickling / chromeless

🖥 Chrome automation made simple. Runs locally or headless on AWS Lambda.
https://chromeless.netlify.com
MIT License
13.25k stars 574 forks source link

Making .wait even faster #85

Open aaronshaf opened 7 years ago

aaronshaf commented 7 years ago

The DevTools protocol allows one to add a script to evaluate on page load (Page.addScriptToEvaluateOnLoad). We could inject a mutation observer that triggers upon DOM changes. We could listen for these instead of using a 500ms interval for evaluation. I will experiment this weekend.

joelgriffith commented 7 years ago

Once https://github.com/graphcool/chromeless/pull/97 lands (or something to that effect), we'll have a clear path for doing mutation observers or likewise