Re:Migrating 300k LOC from Flow to TypeScript
by breatheoften on Thursday June 20, 2019 @10:09AM
(#20233078)
There are libraries that let you define runtime schema objects which you can invoke to validate incoming data — and they also let you extract static types from those schemas so you don’t have to write things twice:
https://github.com/gcanti/io-ts https://github.com/pelotom/runtypes