What is Babel?
What is TypeScript?
Want advice about which of these to choose?Ask the StackShare community!
Typescript has been a win because, in general, it makes codebase maintenance less brittle. It's significantly easier to refactor in TS than JS, which encourages incremental improvements, file re-organizing, etc. Our developers are happier with the overall development experience.
The downside is that TS sometimes exacerbates problems caused by Node's fragmented ecosystem. Sometimes @types/
If your project is big enough, I'd say TS is nearly always worth it, but it can make selecting libraries a pain.
Babel is awesome! 100% of the code for Cloudcraft.co is transpiled from ES2015 (even some ES7 extensions, like decorators and class properties!), using Gulp+Browserify for the frontend and on-the-fly translation in the Node.js backend. Babel allows us to use all the features of future JS, today, giving us a efficient and clean codebase. Overall, it has been an exceptionally smooth adoption, everything Just Works(tm), including debugging with source maps, etc.
Used for Node.js personal projects that I think will have a longer lifetime than others, or that are combined with a web front end component like Angular (to share types).
Generally a poor developer experience. Usage decreasing recently compared to other preferred programming languages/platforms.
TypeScript is used in Kuro (https://github.com/Marc3842h/kuro).
When you are using modern (or sometimes experimental) features of the language, you’ll eventually have to transpile them so that your app works in a wide spectrum of user agents.
Babel is the transpilation tool of my choice.
Excellent design-time type checking and the ability for the Typescript compiler to attach typing information to metadata at compile time allows for relatively simple type checking at run-time as well.
Babel transpiles ES6/ES2015+ code to a format older browsers (*cough* IE *cough*) can understand. This allows developers to write modern JS code while remaining compatible with older systems.
We, our team can sleep comfortable at night know "x is undefined" will not occur in production. It's also really helpful as IDE help in code completion when they know types.
Babel is used in Kuro (https://github.com/Marc3842h/kuro).
Kuro is the browser facing portion of shiro. We use Babel as a easy to use build system for our frontend stack.