master the `rootMargin` option in intersection observer.
The Intersection Observer API has been around for a few years now and has pretty good browser...
Tags: intersectionobserver, dom, javascript