intermediatetermComponentsComponents / Hooks
IntermediateNot yet reviewed

Hooks

Hooks are React functions, with names starting with use, that let a component hold state or run code at certain moments.

Definition

Hooks are React functions, with names starting with use, that let a component hold state or run code at certain moments.

Use case

The useState hook stores a value such as whether a menu is open. Custom hooks bundle logic so it can be reused.

Related terms

Resources

No resources yet. Suggest one.

Suggest a change