[Bug 20246] Provide a system to observe nodes entering and leaving the viewport

https://www.w3.org/Bugs/Public/show_bug.cgi?id=20246

Yoav Weiss <yoav@yoav.ws> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |yoav@yoav.ws

--- Comment #9 from Yoav Weiss <yoav@yoav.ws> ---
@louisremi - If browsers can expose which nodes enter or leave the viewport,
they can also use that info to apply their own logic (e.g. stop animating
elements that are not in the viewport).

I think the major use-case here is for lazy loading of content (prob. mostly
images & HTML/JSON).
The images case is (partially) handled by the proposed "lazyload" attribute[1].
It doesn't give the author control over when & how (nor if) the image will in
fact lazy load. That control stays in the browser (which doesn't match the
extensible-Web philosophy). It does guaranty that these images won't block
onload though.

Personally, I think the proposal is interesting and can be useful as a
low-level API that enables libraries to extend on. I'm not sure it is
implementable in a performant way, though. I'd love it if some browsers folks
that deal with these code areas can share their opinions on the matter here.

[1]
https://dvcs.w3.org/hg/webperf/raw-file/tip/specs/ResourcePriorities/Overview.html

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Monday, 24 June 2013 08:37:17 UTC