Re:Full-Stack TypeScript, React, Apollo, and Node Example
by ng12 on Wednesday May 15, 2019 @05:01PM
(#19923724)
I am completely unconvinced by this argument. Who's shipping un-minified, un-transpiled, un-bundled ES6? And even if you were, TypeScript is just a superset of ES6, to the point where there's even a babel plugin to simply strip the types leaving you with regular ES6 JavaScript. I don't believe that the addition of TypeScript would add any debugging burden to an existing ES6 project.
It's not like we're compiling Haskell to JavaScript, I've never had trouble debugging because of differences between TypeScript and my build output. I honestly don't even think about it.
Just as with as with any transpiler, you never have 100% confidence in your source maps, especially if you mix and match your tooling.
And you almost always loose some part of native debugger functionality in browser or node. I never ever saw a transpiler that does not break correct display of properties along the prototype chain or breakpoints inside constructor functions.
This is where vanilla es6 blows everything away. I know not so few dotcom tier companies with 1m+ per hour websites which stick with handwritten JS on the frontend solely because of that: productivity gains for them simply not worth losing few percents of visitors because of hard to catch and debug bugs.