1// Load element when in viewport 2 3const lazyInit = (element, fn) => { 4 // console.log("lazyLoadWithIntersectionObserver.js"); 5 const observer = new IntersectionObserver((entries) => { 6 if (entries.some(({isIntersecting}) => isIntersecting)) { 7 observer.disconnect(); 8 fn(); 9 } 10 }); 11 observer.observe(element); 12};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.