How to stop revalidating after data meets condition? #792
Answered
by
shuding
jonasmerlin
asked this question in
Q&A
-
So I'm using SWR to query an endpoint with I guess I can see a solution with useRef for the |
Beta Was this translation helpful? Give feedback.
Answered by
shuding
Nov 27, 2020
Replies: 1 comment 1 reply
-
I'd still use a state for it. It's not overkill because it is an app state (a ref will not trigger a re-render so a state should be better). |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
jonasmerlin
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'd still use a state for it. It's not overkill because it is an app state (a ref will not trigger a re-render so a state should be better).