Last updated
Last updated
Use https://github.com/thebuilder/react-intersection-observer
instead its faster cuz new browser api
Run a function when a waypoint is reached
A waypoint normally fires onEnter
and onLeave
as you are scrolling, but it can fire because of other events too:
When the window is resized
When it is mounted (fires onEnter
if it's visible on the page)
When it is updated/re-rendered by its parent
infinite scroll
Change, add CSS on scroll