W3C home > Mailing lists > Public > www-style@w3.org > November 2014

Re: [css-fonts] font prefetch hints

From: Yoav Weiss <yoav@yoav.ws>
Date: Wed, 12 Nov 2014 00:20:35 +0100
Message-ID: <CACj=BEj9dpUOs93HfHHUtSkdygePJ3TOfozySi-NNoMWufPpOw@mail.gmail.com>
To: Ilya Grigorik <igrigorik@gmail.com>
Cc: "Tab Atkins Jr." <jackalmage@gmail.com>, Zack Weinberg <zackw@panix.com>, www-style list <www-style@w3.org>
Regarding the opt-in for preloading purposes, I believe (but have not
proved yet) that it may not be necessary, and that CSS based resources can
be preloaded without it, at least for the majority of cases.

The HTML preloader can keep track of tag names, IDs and class names it
encounters (and whether they contained text). A CSS preloader can then scan
CSS tokens, find resources, and assuming they have a simple selector, see
if they should be downloaded and if so, kick off that download.

The tricky parts would be:
* CSS rules that get overridden further down the line.  I need to gather
data about how often that happens, since that may trigger needless
* Complex selectors that trigger resource download - Keeping track of
complex relationships won't be feasible, so such resources won't be
preloaded. Again, need data.
* Unicode ranges for text - They would be harder to track. Maybe we can
flag tokens with popular ranges, but it's trickier.

If anyone has data regarding the frequency in which the first two points
appear in the wild, I'd be very interested to hear it.
Received on Tuesday, 11 November 2014 23:21:01 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:48 UTC