TypeScript snippets
TS
web
03/26/2025
Wraps the provided type, making any null or undefined properties required. Pulled from: https://stackoverflow.com/a/53050575/3757297
type NoUndefinedField<T> = { [P in keyof T]-?: NoUndefinedField<NonNullable<T[P]>> };