setState is a method used in React to update the state of a component. When setState is called, React re-renders the component and its children, reflecting the updated state.
Here's a detailed explanation of what happens under the hood when setState ...