Re: DOMContentLoaded

Nicolas Mendoza wrote:
> Specifically, with Mozilla Firefox, CSS style attributes from external 
> stylesheets are applied to the DOM tree before DOMContentLoaded is 
> fired.

In Mozilla DOMContentLoaded is fired when the end of the document is parsed (the 
</html> in HTML documents).

Depending on timing of network events, stylesheets may or may not have loaded 
before then.

Note that released Gecko builds block the parser on stylesheets just like they 
do for scripts.  Thus DOMContentLoaded always fires after stylesheets have 
loaded in release Geckos.  That's not going to be the case in Gecko 1.9.

> In Opera it's fired when the tree is done and styles are applied 
> later.

I find it hard to believe that this is true in all cases, because this would 
imply that Opera doesn't do incremental rendering.  My experience is that it does.

-Boris

Received on Monday, 9 July 2007 02:12:39 UTC