CodeZettaInterview Hub

TypeScript · Type Safety · Mid-Level · Debugging

Non-null assertion (!) risks?

Short Interview Answer

Tells compiler to ignore nullish — can crash at runtime if wrong.

Detailed Explanation

Prefer narrowing. Reserve ! for proven invariants after checks.

Did you know this answer?