package.json: Engines & engineStrict - And How to Use Them
March 24, 2015
I’ve been diving into io.js recently for reasons that will soon become clear. In doing so, I’ve used my favorite Node version manager, Node Version Manager, to handle different versions of Node.js and io.js.
Switching between versions is straightforward, but occasionally I end up running code on a version of Node/io.js that the code doesn’t support. For instance, running EcmaScript 6 let statements in Node.js.
I hoped for a warning or even an error to alert me to this mismatch, but none appeared. So…
In this post, I’ll explain how to use the package.json file to get warnings and errors when running code on an unsupported version of the framework.

