Re: The lazyload and postpone attribute for images

On Mon, 09 Sep 2013 13:20:43 +0100, Yoav Weiss <yoav@yoav.ws> wrote:

> I'm also worried with the binding of art-directed images with postponed  
> images. One of the advantages of the current native proposals is that  
> they'd perform better than current JS techniques. This method will  
> prevent that, by forcing the images to wait for layout and be in  
> viewport in order to start the download.

I think opt-in to postponing loading of images after layout may be a very  
useful thing — it opens up interesting possibilities like having  
layout-based media queries.

> Regarding the MQs cluttering the HTML, check out [1] for a discussion on  
> how they can be moved back into CSS land.

Any useful solution that touches CSS won't work with the preload scanner  
and will have to wait until external CSS is loaded (limiting CSS-based  
solutions to work only with inline CSS in <head> could be compatible with  
(a bit smarter) preload scanner, but it'd be weird from authors'  
perspective).

So if you wait RTT or more for CSS variables to load, waiting a bit more  
for layout doesn't seem so bad. Might be worth considering.

-- 
regards, Kornel

Received on Tuesday, 10 September 2013 00:17:27 UTC