FWIW, loading scripts asynchronously with the Script DOM Element approach
does not block window.onload in IE. In Chrome and Safari, the downloading
blocks, but execution doesn't. In Firefox and Opera, downloading and
execution blocks.
So, it's pretty hard to say what web developers would expect
Right. Async scripts aren't really asynchronous if they block all the
user-visible functionality that sites currently tie to window.onload.
I don't know if we need another attribute, or if we just need to change the
behavior for all async scripts. But I think the best time to fix this is
now;
How do I correctly set a boolean
attributehttp://dev.w3.org/html5/spec/Overview.html#boolean-attributeson
a DOM element object in Javascript?
var script = document.createElement('script');
1. script.async = true;// makes the most sense, but appears go
against the spec
2.
not to.
-Brian
On Tue, Dec 8, 2009 at 1:41 PM, Tab Atkins Jr. jackalm...@gmail.com wrote:
On Tue, Dec 8, 2009 at 1:49 PM, Brian Kuhn bnk...@gmail.com wrote:
How do I correctly set a boolean attribute on a DOM element object in
Javascript?
var script = document.createElement('script
. jackalm...@gmail.com wrote:
On Tue, Dec 8, 2009 at 3:48 PM, Brian Kuhn bnk...@gmail.com wrote: but
it's invalid to set it ...
Indeed, async=true does set it to be on. However, so does
async=false, async=off, async=no, and any other string you can
think of that might imply that it's turned off
Thanks Tab, and everyone else. This has been enlightening!
On Tue, Dec 8, 2009 at 3:22 PM, Tab Atkins Jr. jackalm...@gmail.com wrote:
Some clarification is in order; I didn't answer fully and was
corrected elsewhere.
There are two distinct notions of attributes here. The first, the
In section
4.3.1http://www.whatwg.org/specs/web-apps/current-work/#attr-script-async,
it says:
*Fetching an external script must delay the load event of the element's
document until the task that is queued by the networking task source once
the resource has been fetched (defined above) has been
Is there any limit to the length of message you can send with postMessage
(HTML5 Cross-document messaging)?
I didn't see anything in the spec about this. I thought this might be one
area where implementations might end up differing.
Thanks,
Brian
Does anyone know of any browsers actually planning to support the async
attribute? From the quick survey I've done, it doesn't appear they are.
Anyone have any thoughts on what's holding them back?
-Brian
On Wed, Sep 30, 2009 at 9:59 PM, Darin Fisher da...@chromium.org wrote:
On Wed, Sep