W3C home > Mailing lists > Public > public-web-perf@w3.org > January 2018

Re: Using preload for "async" CSS by changing `rel` trick

From: Ben Maurer <ben.maurer@gmail.com>
Date: Fri, 12 Jan 2018 22:24:08 -0800
Message-ID: <CABgOVaJjNBGnernPjg1SEJ-dGwjjF5Cg2FmpDHxisozOwM3C0A@mail.gmail.com>
To: Ilya Grigorik <igrigorik@google.com>
Cc: Philip Walton <philipwalton@google.com>, Royi Hagigi <royi@fb.com>, "public-web-perf@w3.org" <public-web-perf@w3.org>
>
>
>
>> We use the fact that a resource has been downloaded to reveal content
>> that depends on the JS/CSS that we are fetching. So if rel=preload told use
>> a.css is available we'll insert HTML that uses a.css into the DOM. Even a
>> single frame of the browser doing something like parsing the file would
>> create a disruptive user experience.
>>
>
> Right, I see. I think that's a great use case to raise against HTML spec
> and see what the guidance is there — this is not preload specific, same
> applies for resources coming from HTTP cache, serviceworker, etc.
>
>
Is the correct formulation of the question "does the presence of a resource
in the fetch group's response cache [which is what the preload spec says it
adds the stylesheet to] guarantee that inserting a <link> with an href to
that resource will synchronously apply to the DOM"

-b
Received on Saturday, 13 January 2018 06:24:32 UTC

This archive was generated by hypermail 2.3.1 : Saturday, 13 January 2018 06:24:33 UTC