[whatwg] HTMLLinkElement.disabled and HTMLLinkElement.sheet behavior

Julien Chaffraix jchaffraix at webkit.org
Tue Oct 4 11:41:57 PDT 2011


Hi everyone,

following WebKit's attempt at implementing the behavior of |sheet| and
|disabled| per HTML5 / CSSOM [1], we have found that the specs [2] [3]
either under-specify the behavior or do not match what browsers are
doing.

Here are the behaviors seen during testing:
* IE9 does not support link.sheet.
* Opera and FF always have an associated stylesheet if |link.rel|
matches a stylesheet and |href| is set.
* They both fill link.sheet with default values even if the stylesheet
was / ends up in error.
* However, FF loads the stylesheet synchronously whereas Opera does it
asynchronously from a JS perspective
* 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.

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.

Thanks,
Julien

[1] https://bugs.webkit.org/show_bug.cgi?id=65140 (see in particular
comments #26 [our reading of the spec] and #29 [some findings summed
up here for easier reading])
[2] http://www.whatwg.org/specs/web-apps/current-work/multipage/semantics.html#dom-link-disabled
[3] http://dev.w3.org/csswg/cssom/#the-linkstyle-interface


More information about the whatwg mailing list