How to target only first and last intersected elements with Intersection Observer?

Something like

 if (entry.isIntersecting) {
        if(entry.isIntersecting[0]) {
// do your thing
 }
}

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.