Check if the runtime is io.js instead of Node.js
$ npm install --save is-io
const isIo = require('is-io');
if (isIo) {
// Do something custom in io.js
} else {
// And something else in Node.js
}
MIT © Sindre Sorhus
Check if the runtime is io.js instead of Node.js
$ npm install --save is-io
const isIo = require('is-io');
if (isIo) {
// Do something custom in io.js
} else {
// And something else in Node.js
}
MIT © Sindre Sorhus