All challenges
Multiple ChoiceIntermediate 30s

Structured error handling

Choose the best answer for: error objects
Options
  1. 1Throw plain string values and match on their text in each catch
  2. 2Custom error classes with code, statusCode, and details
  3. 3Use only the built-in Error(), with no code or statusCode field
  4. 4Throw no typed errors, propagating failures as generic objects

Think you can answer under pressure?

Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.

Play this in a 3-minute battle