This page is about the local state of a component.
In React, this local state is known as state
If you need to persist local state, you should:
In React apps, whether a component is stateful or stateless is considered an implementation detail of the component that may change over time. You can use stateless components inside stateful components, and vice versa.
See the dedicated page: React - How to persist the local state between rendering without any library? (custom useState Hook)
Check the dedicated page: