Earlier quoted context omitted.
TS is great but lack of pattern matching cripples the language somewhat
It helps that is has good smart-casting, you can do with an if where other languages need pattern matching const x: { t: 'A', foo: string } | { t: 'B', bar: string } = /*...*/ return x.t === 'A' ? x.foo : x.bar
Re: Scala 3.0
#291It is cool syntax trick, but it won’t make compiler tell you when you missed a case