Typescript's type system isn't sound. The Set theoretical type system proposed for Elixir is.
If Elixir can pull off soundness without compromising expressivity that will be a huge feat, and I'm excited to see it!
[0] https://www.typescriptlang.org/play/?strictFunctionTypes=fal...
That being said, I don’t think it’s possible to “pull off soundness without compromising expressivity” because the expressivity in this context is self-referential types which equate to non-terminating unification logic (and thus, unsoundness). Still, I’m excited to see what they do with this type system! Reminds me a bit of Shen’s type system.
(Edit: to be clear, allowing to refine function types in the way they do is part of the solution, the unsound part is that it is not checked afaik)