Introduction

Get introduced to state and lifecycle methods in React.

We'll cover the following

We will look at state and lifecycle methods briefly.

State

Components can:

  1. Hold
  2. Manage
  3. Change their own state.

But if the state within a component changes, it always triggers a re-render of the component. This behavior can be avoided by opting for a PureComponent, which might be useful in some cases. The foundational logic remains, though.

Create a free account to view this lesson.

By signing up, you agree to Educative's Terms of Service and Privacy Policy