using useControls with useState react 18 #515
Unanswered
mohamed2020m
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi guys,
I have a situation where I am fetching some data from the backend, this data is being stored in a state, the function that is responsible to fetch it is in the useEffecte. so after that I use that data to dynamically create folders and pass them to useControls, Like this:
The problem I am facing is that when new data is fetched, the old ones always stay in the controls. I've tried to add a dependency in the dependencies array of useControls but it's not working.
Does anyone have an idea how to solve this problem?
tnx.
Beta Was this translation helpful? Give feedback.
All reactions