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

Which is why the title is "Node can now execute Typescript files" and not lint, check, or even run TypeScript files.




I'm not sure what the distinction between "execute" and "run" is; is there a difference?

No, I don't think there really is. But to be execute is even more clear that it's just... executing the code, whereas I could maybe understand someone being confused that run implied some level of type checking.

Node is just inline transpiling the TS into JS, then running the JS.

This is misleading. It is not transpiling TS in JS, it is transpiling a subset of TS into JS. If my normal TS code can not be "executed" by Node, then it is not executing TS per definition but something else. If you are good with Node supporting and "executing" only a subset of TS and lacking useful features, that's fine. But don't tell people it is executing TypeScript. That's like me saying my rudimentary C++ compiler supports C++ while in reality only supporting 50%. People would be pissed if they figure it out once they try to run it on their codebase.

It's quite close to 100%. It makes one extra-strictness toggle mandatory. Saying it's not TS is much more misleading.



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

Search: