Hacker News new | past | comments | ask | show | jobs | submit login

I'm mostly concerned with using APIs that are only available in io.js. Doing so means I can't share my modules in any reliable way since io.js and node both use npm and I certainly wouldn't create multiple versions of my modules. This leaves me developing using only node APIs at which point io.js is nice for experimentation but I'm not sure about doing serious work for it until it's strictly an application (no module sharing, etc).

Really the biggest sticking point for me is using npm between the two. Node not supporting ES6 is also an issue as you can't write your code using ES6 unless you want to only support io.js or you want to transpile (ugh).




That's a valid point. Perhaps package.json should support a property that defines which version of node/io.js are supported in the module.

This probably already exists in node world regarding binary dependencies. I use at least one that's only compatible with 0.10 but there's no way to know that until you get a build error on 0.12.


Yes, it exists (the 'engine' field).


This exists but now you're limiting your audience to use APIs and syntax in a slightly newer, different version of node (io.js). I'm not convinced that's worth it in my opinion. I'm not sure npm can support using the same package name deployed under different engines (it doesn't appear to as far as I can tell) but that's annoying to maintain.


Is there a list of APIs that are only available in io.js to help us avoid them?


Anything ES6y implemented in modern versions of V8 that aren't in the version that Node.js is using cannot be used. E.g., if you use `"strict mode";`, `const` works in an ES6 way in io.js but throws a syntax error in Node, though if you don't use `"strict mode";` you continue to get the pre-ES6 non-standard `const` that V8 has provided for a long time.

A minor one is that in io.js, `require('events') === require('events').EventEmitter` while that's not true in Node (where require('events') just gives an object with `EventEmitter` and possibly other properties on i.


Current jsdom needs a stable v8, so only works on iojs




Consider applying for YC's W25 batch! Applications are open till Nov 12.

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

Search: