Question · JavaScript and React course · Module 11: Data Fetching and APIs
Error Boundary in React
What is an Error Boundary in React and when does it activate?
Answer options
- It is a server middleware that filters erroneous requests
- It is a special try/catch block built into JSX
- It is a class component that catches rendering errors in its children - it activates when a descendant component throws an error
- It is a hook that catches fetch errors - it activates on every network error
You can check the correct answer by solving this task in the CodeWorlds game.