Skip to content

Instantly share code, notes, and snippets.

@Ivanopalas
Created September 7, 2015 19:09
Show Gist options
  • Save Ivanopalas/310990cefd80d692677d to your computer and use it in GitHub Desktop.
Save Ivanopalas/310990cefd80d692677d to your computer and use it in GitHub Desktop.
// The basic check
if(document.readyState === 'complete') {
// good to go!
}
// Polling for the sake of my intern tests
var interval = setInterval(function() {
if(document.readyState === 'complete') {
clearInterval(interval);
done();
}
}, 100);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment