4 ms·
To add to what oxplot and onion2k said, with both PhantomJS and Electron (when using xvfb) I have found that waiting for the DOMCotentLoaded or with PhantomJS t
by samwillis 10y ago
To add to what oxplot and onion2k said, with both PhantomJS and Electron (when using xvfb) I have found that waiting for the DOMCotentLoaded or with PhantomJS the onLoadFinished event (I think this is similar to documentRequestIdleCallback) usually works.
However sometimes the page still hasn't finished drawing and so I do a couple of requestAnimationFrame's after the DOMCotentLoaded to ensure that everything is drawn to the screen buffer.