Types are erased in typescript, but you can write generics with `extends typeof Thing` and do runtime type checks: https://effectivetypescript.com/2020/07/27/safe-queryselector/
miniblog.
Related Posts
Difftastic 0.71 is out! This is a polish release, still well worth upgrading:
* A ton of performance improvements, especially for nasty corner cases.
* Improved C++, Dockerfile, Haskell, JavaScript, Makefile, Perl, Ruby, Rust, Scala and TypeScript.
Writing type params with <> (e.g. List<Int>) seems the most natural to me: probably because I encountered that syntax first.
Between C++, Java and TypeScript I think it's the most common too.
List[Int] seems to be next most common (Scala, Python) but TIL Gleam uses List(Int)!
Delighted to see that Typescript 7 is moving to conventional LSP for its IDE services!
