Skip to content

Instantly share code, notes, and snippets.

@eduardolundgren
Created August 22, 2017 04:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save eduardolundgren/1247fedb8ec26b22a83e7bc24ad7f4e6 to your computer and use it in GitHub Desktop.
Save eduardolundgren/1247fedb8ec26b22a83e7bc24ad7f4e6 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<body>
<script>
assert(document.readyState === 'loading');
document.addEventListener("DOMContentLoaded", function() {
assert(document.readyState === 'interactive'); // <--
setTimeout(function() {
assert(document.readyState === 'complete');
}, 0);
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment