News for hackers. Stuff that matters.
Re:JavaScript for Impatient Programmers by e12e on Thursday July 02, 2020 @09:00AM (#23712658)
Don't really disagree with that. On the other hand, npm/yarn is generally a dependency you can't get away from - so if your needs aren't complex, I'd say in general, you're better off with a simple npm/yarn config, than pulling in another dependency.

Of course pulling in python in a python project is free, if python is tightly coupled to the js stuff anyway.

Often eg: the front end will be just js/ts - and reusable/useful without any python.

Re:JavaScript for Impatient Programmers by IshKebab on Friday July 03, 2020 @09:36AM (#23723869)
Yeah to be honest we don't use Python for anything other than the build system, but it is available on all our systems so it is easy to use, and I couldn't find anything better. I would have liked to be able to use Typescript, but 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".
Re:JavaScript for Impatient Programmers by e12e on Friday July 03, 2020 @09:11PM (#23729132)
> 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/

> 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

  npx ts-node script.ts
https://stackoverflow.com/a/33536053