1 min read 25 words Updated Oct 03, 2026 Created Oct 03, 2026
#TypeScript

Allowing for adding multiple possible data types:

let name: string | null = null; 

TypeScript does not infer union types, just single types.