triggerOnce prop not working for <InView />, creates infinite loop #667
Unanswered
bushidavid
asked this question in
Q&A
Replies: 1 comment 1 reply
-
I imagine this is Next.js remounting the entire component when you trigger a server action. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey guys, I'm having a problem with IntersectionObserver. I have added the triggerOnce prop to the component but this seems to not be working, and it's causing an infinite loop.
The onChange triggers an handInView() function that updates data on database.
Below is my code:
Any idea what could be the problem? Could it be because the component is being rerendered?
Beta Was this translation helpful? Give feedback.
All reactions