4 ms·
There is no compilation step in the js world, or any other interpreted language for that matter. Even in case of JIT, it happens completely transparently and ha
by usrnm 7y ago
There is no compilation step in the js world, or any other interpreted language for that matter. Even in case of JIT, it happens completely transparently and has no effect on the package you download from npm. Nobody distributes JIT'ed code.
C++, on the other hand, doesn't work like that. Source code needs to be compiled to be usable and the exact way it is supposed to be compiled varies enormously between different projects. Not to mention that there are usually lots of compiler options and project-specific macro definitions that you might want to change to get the exact binary you need. Compilation matters, it matters a lot, and it cannot be easily abstracted away without sacrifising performance and flexibility.
- yunyu 7y agoPlenty of npm/pypi modules require building platform-specific native code (see node-gyp, wheel), and a lot of JS packages require transpilation. I don't find this argument particularly compelling.