diff --git a/Readme.md b/Readme.md index 389a663..04facf2 100644 --- a/Readme.md +++ b/Readme.md @@ -19,12 +19,10 @@ $ npm install koa ``` - To use Koa you must be running __node 0.11.13__ or higher for generator and promise support, and must run node(1) - with the `--harmony` flag. If you don't like typing this, add an alias to your shell profile: + Koa is supported in all versions of [iojs](https://iojs.org) without any flags. -``` -alias node='node --harmony' -``` + To use Koa with node, you must be running __node 0.11.16__ or higher for generator and promise support, and must run node(1) + with the `--harmony-generators` or `--harmony` flag. ## Community diff --git a/docs/api/index.md b/docs/api/index.md index 07cd5ed..3c78db8 100644 --- a/docs/api/index.md +++ b/docs/api/index.md @@ -1,11 +1,16 @@ # Installation - Koa currently requires node 0.11.x for the --harmony flag which exposes generators to your script. If you're running an earlier version of node you may install [n](https://github.com/visionmedia/n), a node version manager to quickly install 0.11.x: + Koa is supported in all versions of [iojs](https://iojs.org) without any flags. -``` -$ npm install -g n -$ n 0.11 -$ node --harmony my-koa-app.js + To use Koa with node, you must be running __node 0.11.16__ or higher for generator and promise support, and must run node(1) + with the `--harmony-generators` or `--harmony` flag. + + You can quickly install a supposed version of node/iojs with your favorite version manager: + +```bash +$ nvm install iojs +$ npm i koa +$ node my-koa-app.js ``` # Application @@ -179,4 +184,3 @@ app.on('error', function(err, ctx){ When an error occurs _and_ it is still possible to respond to the client, aka no data has been written to the socket, Koa will respond appropriately with a 500 "Internal Server Error". In either case an app-level "error" is emitted for logging purposes. - diff --git a/package.json b/package.json index adc131a..26b5294 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,8 @@ "test-console": "^0.7.1" }, "engines": { - "node": ">= 0.11.13" + "node": ">= 0.11.16", + "iojs": ">= 1.0.0" }, "files": [ "lib"