useState Hook
useState registers a state cell on the component's fiber and returns the current value plus a setter; calling the setter schedules a re-render rather than mutating the value in place. The value is a per-component snapshot: it stays constant for the duration of one render, even after the setter is called.
This Concept is waiting for its first lesson!
useState registers a state cell on the component's fiber and returns the current value plus a setter; calling the setter schedules a re-render rather than mutating the value in place. The value is a per-component snapshot: it stays constant for the duration of one render, even after the setter is called.
Are you a teacher? Sign in to start contributing.
Sign In