Re: [ResourcePriorities] Scripts and integration with HTML spec

It definitely makes sense to spec this straight in the HTML spec. Ian,
would you take it over then? James/Jatinder, is that ok with you?

Arvind


On Mon, Dec 9, 2013 at 11:54 AM, Ian Hickson <ian@hixie.ch> wrote:

>
> I was recently introduced to the Resource Priorities spec, in the context
> of a discussion at the WHATWG for how to provide more control to authors
> around loading of scripts and the <script> element.
>
> I'm interested in making sure that we don't end up with conflicting
> requirements, or a weird inconsistent design overall (with some elements
> working one way but others working another).
>
>
> The Resource Priorities spec proposes that the <script> element support an
> attribute that basically acts like async="" except it makes the loading
> have an even lower priority.
>
> The use cases that I studied for script preloading need more than just
> that; in trying to address them I proposed a couple of new attributes that
> set up a dependency mechanism (search for "Here's a proposal" to jump to
> the meat of the e-mail):
>
>
> http://lists.w3.org/Archives/Public/public-whatwg-archive/2013Aug/0277.html
>
> (The proposal has issues and wouldn't be adopted as is; the point is just
> to illustrate that the proposal overlaps with the Resource Priorities
> proposal and isn't trivially the same.)
>
> Does anyone have an opinion on how we should proceed here?
>
>
> Regarding the other elements: in general, we should probably integrate the
> HTML aspects of the Resource Priorities spec more closely with the
> processing models in the HTML spec. (For example, "The User Agent parser
> MUST NOT block launching new script contexts on stylesheets" conflicts
> with the normative text in HTML around the concept of "a style sheet that
> is blocking scripts".) There's several ways we could do this; we could
> simply have it all speced in the HTML spec, or we could adjust the
> Resource Priorities spec to hook into the HTML spec -- in the latter case,
> I'd be happy to provide any required hooks to make that easier.
>
> What's the implementation status of this proposal? Does it have browser
> vendor buy-in? Do people think we should spec this in straight in the HTML
> spec, or would a hook-based approach work better for people?
>
>
> It may also be worth making sure that we bear in mind this request
> regarding cookie control:
>
>    https://www.w3.org/Bugs/Public/show_bug.cgi?id=11235
>
> Since it affects the same features for which you'd want to control load
> priorities, it might want to use the same mechanism. I haven't studied
> this particular problem in detail yet. The security-focused CSP may also
> be a way to address this particular problem.
>
> --
> Ian Hickson               U+1047E                )\._.,--....,'``.    fL
> http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
> Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
>
>

Received on Monday, 17 March 2014 23:01:35 UTC