Sending more data to primarily empower mobile devices sounds rather
counter-intuitive
On Sep 18, 2012 7:06 PM, "Brion Vibber" <brion(a)pobox.com> wrote:
On Tue, Sep 18, 2012 at 9:38 AM, Trevor Parscal
<tparscal(a)wikimedia.org
wrote:
In VisualEditor we ended up putting all CSS rules
that include images in
*.icons-raster.css and *.icons-vector.css files, which are loaded
dynamically based on the window.devicePixelRatio property.
It has it's flaws, but the good thing is that it spares the device from
loading both versions. I dislike the approach we are using and am open
minded to alternatives, but any solution that makes a client load both
isn't really going to work.
It's great to avoid loading both when you can, and with CSS icons that's
relatively doable.
For what it's worth though, a (different) load-both scenario is in actual
use on
http://www.apple.com/
It's not perfect, but as a workaround until srcset is live I'm happy enough
with it. Think of it as progressive loading. ;)
-- brion
_______________________________________________
Wikitech-l mailing list
Wikitech-l(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l