4

React Hooks question: those states we create in functional components, are they just for UI purposes or does it have use for overall the app? Please enlighten me!

Comments
  • 3
    Since the state is all dependent on the order of state calls its most likely only valid for the specific call. If you need it elsewhere you need to pass the variable and setter function around.
Add Comment