...

/

React Class Components: State

React Class Components: State

Learn how to set state for a react class component.

We'll cover the following...

Before React Hooks, class components were superior to function components because they could be stateful. With a class constructor, we can set an initial state for the component. Also, the component’s instance (this) gives access to the current ...