in Chrome 46 and Firefox 42, and it’s not working. I can get it to work if I try it on
window, as in
The MDN documentation for the “load” event says
Target: Document, Element
So why doesn’t it work on the document? Do the docs need to be updated?
The spec states that it is fired at
window and at certain (special) elements like
Fired at the Window when the document has finished loading; fired at an element containing a resource (e.g. img, embed) when its resource has finished loading
window.addEventListener('load', handler) the proper way to do things when the document is ready (DOM loaded, but images, etc still need to load)?
DOMContentLoaded event of the