[whatwg] HTMLLinkElement.disabled and HTMLLinkElement.sheet behavior
bzbarsky at MIT.EDU
Tue Oct 4 11:54:34 PDT 2011
On 10/4/11 2:41 PM, Julien Chaffraix wrote:
> * However, FF loads the stylesheet synchronously whereas Opera does it
> asynchronously from a JS perspective
Uh... Firefox does not load anything synchronously.
What Firefox does do is block execution of <script> tags (but not
timeouts, callbacks, etc!) if there are pending non-altenate
parser-inserted stylesheet loads. This is necessary to make sure that
scripts getting layout properties see the effect of those stylesheets.
A side-effect is that a <script> coming after a <link> will never see
the link in an unloaded state... unless there's a network error for the
<link> or whatever.
> * Some websites (4chan.org for examples) assumes that the |sheet| is
> always available and that |disabled| will work properly regardless of
> when it is called.
OK. That behavior is allowed by the spec as far as I can tell.
> We ended up reverting our changes due to incompatibilities seen in the
> wild and seek the spec amended before resuming our implementation in a
> compatible manner.
What specific changes do you want to the spec? As far as I can tell,
right now the spec says nothing about when sheets become associated and
that this would need to be defined, right? Anything else?
More information about the whatwg