2

Is there a flag that is automatically set after window.onload such as window.isLoaded or window.loaded or window.isDOMContentLoaded? (no jQuery)

Ludovic C
  • 2,735
  • 18
  • 39

1 Answers1

4

document.readyState

if (document.readyState === "complete") would be the condition to check.

Found this here: Javascript - How to detect if document has loaded (IE 7/Firefox 3)

Community
  • 1
  • 1
Tony L.
  • 15,516
  • 8
  • 65
  • 65