You can check the document's readyState value and this way tell if the event was fired or not. Here's the code to run a function named start() when the document has finished parsing:
if (/comp|inter|loadedcomplete|interactive|loaded/.test(document.readyState)) { // In case the document has finished parsing, document's readyState will // be one of "complete", "interactive" or (non-standard) "loaded". // The regexp above looks for all three states. A more readable regexp // would be /complete|interactive|loaded/ start(); } else { // The document is not ready yet, so wait for the DOMContentLoaded event document.addEventListener('DOMContentLoaded', start, false); } Notice that the code above detects when the document has finished parsing. Beware that's not the same as detecting if DOMContentLoaded was fired (which happens immediately after interactive), but it serves the same practical purpose, i.e., it tells you that the document has finished loading and has been parsed, but sub-resources such as images, stylesheets and frames are still loading (source).