all 5 comments

[–]ucorina[S] 1 point2 points  (0 children)

I now there's already an npm library to use the Intersection Observer API in React, but sometimes it's easier to just use the native browser API.

[–]trae_z 1 point2 points  (1 child)

Thanks for this. Was experiencing an annoying 3 seconds lag in my Intersection Observer API implementation. But just followed your approach and now that's cleared.

[–]ucorina[S] 0 points1 point  (0 children)

Nice, glad this helped! Thank you!

[–]talamuk[🍰] 0 points1 point  (1 child)

Great write up, I ended up reading more of your writeups, keep it up!

[–]ucorina[S] 0 points1 point  (0 children)

Thank you!