- From: Boris Zbarsky <bzbarsky@MIT.EDU>
- Date: Mon, 18 Oct 2010 00:48:37 -0400
- To: Adam Barth <w3c@adambarth.com>
- CC: public html <public-html@w3.org>
On 10/18/10 12:36 AM, Adam Barth wrote: >> No, because that defers the scripts to onload. The goal here is to execute >> a set of scripts as soon from now as possible, but in a particular order. > > I believe defer doesn't wait until onload. It just wants for parsing > to be finished Fair, it defers to DOMContentLoaded. Which still introduces an undesirable ordering dependency on parser-created scripts, if nothing else. > That's seems like a good balance of performance and predictability. Good for whom? > The scripts are loaded in parallel, but executed in order relative to > each other and relative to inline / external scripts in the document. This last is not desirable, as I understand. >> 1) Which change(s) are we talking about here?? There are at least 3 >> mutually exclusive proposed changes at this point, I think. > > Honestly, I'm lost w.r.t. all the proposals. Yes, I can tell. > There was something about an ordered property that I never understood. It's been withdrawn. Ignore it. > There was a proposal to make non-async script-inserted scripts have order relative > to themselves Yes. > There was a proposal to have async have different semantics on parser- and > script-inserted scripts. Also yes. This proposal was a refinement of the "make non-async script-inserted scripts have order" proposal. The third proposal was to require in-order execution of script-inserted scripts, period. It sounds like you're unwilling to do that; fine. >> 2) I'd be interested in mention of actual sites that are slowed down by the >> changes in question (esp. the one where async is just allowed to apply to >> script-inserted stuff. > > Well, every site on the Internet that uses more than one > script-inserted script without an async attribute. And in which the timing at which the scripts run matters in a meaningful way (in that, say, the scripts aren't just loading API), right? > The proposal was to add an ordering dependency between these scripts. There have been three proposals. At least one doesn't add such a dependency by default, but DOES allow the page to add it if desired. > This has been advocated by web performance experts for a while. For example, read > this article: > > http://www.stevesouders.com/blog/2009/04/27/loading-scripts-without-blocking/ I'd love to, but all it says is: Error establishing a database connection In any case, given your objections so far I think I'm on safe ground in saying that either you're not evaluating Henri's proposal to make async work on script-inserted scripts, or you misunderstood the proposal... -Boris
Received on Monday, 18 October 2010 04:49:13 UTC