[whatwg] RWD Heaven: if browsers reported device capabilities in a request header
hsivonen at iki.fi
Tue Feb 7 05:34:33 PST 2012
On Mon, Feb 6, 2012 at 5:52 PM, Matthew Wilcox <mail at matthewwilcox.com> wrote:
> Also, as indicated, with SPDY this is much much less of a problem than for HTTP.
SPDY transfers the HTTP semantics more efficiently when supported. You
aren't supposed to communicate different semantics depending on
whether SPDY is enabled. That would be a layering violation.
That is, SPDY is supposed to work as a drop-in replacement for the old
way of putting HTTP semantics over IP. You aren't supposed to send
different headers depending on whether SPDY is there or not.
And the old HTTP is going to be around for a *long* time, so even if a
bunch of important sites start supporting SPDY, if browsers send the
same headers in all cases to avoid the layering violation, the long
tail of plain old HTTP sites would be harmed by request size bloat.
So I think "SPDY will fix it" is not a persuasive argument for
allowing HTTP request bloat to cater to the bandwagon of the day.
(Sorry if that seems offensive. You've worked on responsive images, so
they evidently seem important to you, but in the long-term big
picture, it's nowhere near proven that they aren't a fad of interest
to a relative small number of Web developers.)
If there is evidence that responsive images aren't just a fad
bandwagon and there's a long-term need to support them in the
platform, I think supporting something like
<source src=something.jpg media=...>
<source src=other.jpg media=...>
would make more sense, since the added to transfer this markup would
affect sites that use this stuff instead of affecting each request to
all sites that don't use this stuff. This would be more
intermediary-friendly, too, by not involving the Vary header.
The points Boris made about the device pixel size of the image
changing after the page load still apply, though.
But still, engineering for sites varying the number of pixels they
send for photos seems a bit premature when sites haven't yet adopted
SVG for illustrations, diagrams, logos, icons, etc.
hsivonen at iki.fi
More information about the whatwg