layzr.js
layzr.js copied to clipboard
IntersectionObserver API Support
Do you have any plans to support the IntersectionObserver API? It is supposed to be more performant than Element.getBoundingClientRect()
and is becoming widely supported.
will likely update this lib at some point, if i find the time
if you want to use IntersectionObserver for the time being, check out obzerv. it tracks elements relative to the viewport in a more general sense. there's an example on the README that shows how to load an image lazily