News for hackers. Stuff that matters.
Re:TypeScript 3.7: The Biggest Features and How to Use Them by dmix on Thursday September 12, 2019 @06:12PM (#20957011)
Any who builds a new language and doesn’t make pattern matching a big part of the language is seriously missing out.

It’s easily the #1 thing I miss syntax-wise after using Elixir/Erlang for any period of time.

Patterns fit perfectly with the typed and functional approach, especially with Maybe monads which are used everywhere in some apps.

Re:TypeScript 3.7: The Biggest Features and How to Use Them by spankalee on Thursday September 12, 2019 @06:50PM (#20957304)
TypeScript isn't really a new language. It's a (mostly) type-checking-only extension to JavaScript. The team has made a policy of not adding any more runtime behavior changing features. JavaScript will need to add pattern matching for TypeScript to get it.
Re:TypeScript 3.7: The Biggest Features and How to Use Them by dmix on Thursday September 12, 2019 @07:31PM (#20957611)
Oh I know, I actually don't expect it from Typescript. It's portability with JS code is TS's best feature and I don't see how you could marry the two (maybe I'm wrong here). I just wanted to share how much I like pattern matching.