componentDidCatch

A class lifecycle method React calls after a child error, receiving the error and an info object whose componentStack shows which components were rendering.

In more detail

Use it to send the error to a logging or monitoring service. It runs after the fallback has been committed.

Related terms

Taught in

References