Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

That does help a lot and was a long time coming.

TS is a little harder to get started with for a few reasons. For one, it simply does more, with features like interfaces (which "sort of" exist in Flow), and public/private accessors.

One distinct advantage of Flow is that it is not a build step, but is more like a linter. I like this - it doesn't re-invent the wheel, so you don't have to choose between having the latest features or being fully TS-compatible. On the other hand, Flow's typechecking is far less complete, and it still uses its own home-rolled parser which occasionally has issues parsing certain ES2016+ features, such as decorators.

If I were starting a project from scratch, I would likely use TS as it's simply more complete. But if I were migrating an existing project, Flow starts paying off right away and is easy to integrate.



As you mentioned, Flow not being a build step seems to be a big win to me. A lot of different tools use or encourage you to use babel and babel is ahead of TypeScript in ES6/ES7, http://kangax.github.io/compat-table/es6/. If you use TypeScript your chain suddenly becomes much slower/more complex.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: