3 ms·
> there's no really good simple way to say "Node: compile and execute this typescript file, please don't save the output on disk anywhere, or try to read tsconf
by e12e 6y ago
> there's no really good simple way to say "Node: compile and execute this typescript file, please don't save the output on disk anywhere, or try to read tsconfig.json or package.json or whatever".
I guess there's no native typescript support for nodejs (so npx is out). Maybe deno can help?
https://deno.land/ https://deno.land/
> Supports TypeScript out of the box.
Thats clearly a sort of "now you have two problems" type solution - but if there's a desire to stick with ts as a language - it might be helpful? (to drop the python dependency).
Ed: hm, there's apparently ts-node : https://github.com/TypeStrong/ts-node https://github.com/TypeStrong/ts-node
npx ts-node script.ts
https://stackoverflow.com/a/33536053 https://stackoverflow.com/a/33536053