TypeScript · Concept
What TypeScript gives you; type vs interface
Practise this out loud
Say your answer out loud to an AI interviewer that follows up, and get a score for it.
Practise by voiceThe interviewer asks
What is TypeScript and what are its features? When do you use type vs interface?
Then
Follow-ups the interviewer asks next
- Declaration merging (interfaces only); module augmentation for third-party types.
- Unions, mapped and conditional types need
type. extendsvs intersection: error messages and performance.- TS types are erased at runtime, so how do you validate API data? (zod/valibot.)
The answer
What a strong answer covers
- Static typing, inference, tooling and refactoring safety; no runtime checks
- Prefer
interfacefor object shapes and public APIs (extendable),typefor unions and compositions; be consistent
The red pen
Common traps
Avoid:"TypeScript makes the app safer at runtime".
Practise this out loud
Say your answer out loud to an AI interviewer that follows up, and get a score for it.
Practise by voicePractise questions like this out loud
Sign up and start with a 15-minute interview with the full report, and an English conversation. No card needed.