So many runtimes and tools are integrating TypeScript now, and with multiple implementations, that a real standard is necessary. It'll be much harder to evolve TypeScript because it'll have to stay backwards compatible, but it's grown to that point now, imo.
Node.js adds experimental support for TypeScript
11–20 of 570 posts
Re: Node.js adds experimental support for TypeScript
#12Simply amazing! I wonder bun and deno support for typescript played a big role here :)
Re: Node.js adds experimental support for TypeScript
#13Nice to see Node.js getting parity on this with Deno and Bun
This reminds me of io.js situation, where in the end major fork changes were incorporated into Node. This is why I am comfortable staying with Node and npm for my projects - the features will eventually trickle down anyway.
How many days have you spent on webpack config? Or the package.json type property? Or yarn/pnpm/etc particulars?
I have spent too many.
Bun is quite nice.
Re: Node.js adds experimental support for TypeScript
#14Nice to see Node.js getting parity on this with Deno and Bun
On the topic of typescript - yes. However Bun has a lot more tools baked in than Node does at (bun test for instance). Would be real nice to see Node start adopting more ideas from Bun and others.
node has a built in test runner now
Re: Node.js adds experimental support for TypeScript
#15My favorite deno feature is coming to node directly. Awesome! Maybe this means I don't always have to install esbuild to strip types - very excited how this will make writing scripts in TypeScript that much easier to use. I lately have been prefering Python for one off scripts, but I do think personally TypeScript > Python wrt types. And larger scripts really benefit from types especially when looking at them again a…
Re: Node.js adds experimental support for TypeScript
#16So how does this work in practice? Does it strip types and yolo trying to run or will it spit out type errors?
Re: Node.js adds experimental support for TypeScript
#17support for typescript as long as you are only using it for type checking, not if you are also using features that are not supported in the javascript version you are targeting.
If you need JS syntax features that Node.js doesn't support you can use tsc, babel, etc.
Because obviously unsupported features are unsupported, whether JS or TS.
Re: Node.js adds experimental support for TypeScript
#18It's about time for TC39 and Microsoft to standardize TypeScript as part of JavaScript. Not "types as comments" either, but actually TypeScript, minus the non-standard runtime semantics and modulo whatever changes are necessary to integrate the grammar. So many runtimes and tools are integrating TypeScript now, and with multiple implementations, that a real standard is necessary. It'll be much harder to evolve TypeSc…
Re: Node.js adds experimental support for TypeScript
#19So how does this work in practice? Does it strip types and yolo trying to run or will it spit out type errors?
> During the transpilation process, no type checking is performed, and types are discarded
Re: Node.js adds experimental support for TypeScript
#20It's about time for TC39 and Microsoft to standardize TypeScript as part of JavaScript. Not "types as comments" either, but actually TypeScript, minus the non-standard runtime semantics and modulo whatever changes are necessary to integrate the grammar. So many runtimes and tools are integrating TypeScript now, and with multiple implementations, that a real standard is necessary. It'll be much harder to evolve TypeSc…