Y
Hacker News
new
|
ask
|
show
|
jobs
by
adamrezich
844 days ago
yep, sorry about that, I misremembered TypeScript as having the same "kind of enums" as Rust.
1 comments
tubthumper8
844 days ago
TypeScript has discriminated unions if that's what you were thinking of
https://www.typescriptlang.org/docs/handbook/2/narrowing.htm...
link
https://www.typescriptlang.org/docs/handbook/2/narrowing.htm...