Every network request can fail. Handle errors gracefully.
Error types:
- Network errors (offline, timeout)
- Server errors (xx)
- Client errors (xx)
- Validation errors
Handling patterns:
- Retry with backoff: Try again, wait longer each time
- Fallback data: Show cached version
- Error boundaries: Catch errors, show fallback UI
User communication:
- Clear error messages
- Action to recover (retry button)
- Don't lose user's work
Interview tip: Always mention error handling. It shows production experience.