{"name":"koa-conditional-get","description":"Conditional GET support for koa","repository":{"type":"git","url":"git+https://github.com/koajs/conditional-get.git"},"version":"1.0.3","keywords":["koa","middleware","cache","caching","etag"],"files":["index.js"],"devDependencies":{"istanbul-harmony":"0","koa":"0","should":"3","mocha":"1","supertest":"0","koa-etag":"1"},"license":"MIT","dependencies":{},"scripts":{"test":"NODE_ENV=test mocha --harmony-generators --require should --reporter spec","test-cov":"NODE_ENV=test node --harmony-generators ./node_modules/.bin/istanbul cover ./node_modules/.bin/_mocha -- --require should","test-travis":"NODE_ENV=test node --harmony-generators ./node_modules/.bin/istanbul cover ./node_modules/.bin/_mocha --report lcovonly -- --require should"},"gitHead":"6ea1c1891c9d4234d75aba32a6425bc1be66af4c","bugs":{"url":"https://github.com/koajs/conditional-get/issues"},"homepage":"https://github.com/koajs/conditional-get#readme","_id":"koa-conditional-get@1.0.3","_shasum":"91aa03f2888aec0ae2f636f18b0cd95f158510c7","_from":".","_npmVersion":"2.10.1","_nodeVersion":"2.1.0","_npmUser":{"name":"jongleberry","email":"jonathanrichardong@gmail.com"},"maintainers":[{"name":"tjholowaychuk","email":"tj@vision-media.ca"},{"name":"jongleberry","email":"jonathanrichardong@gmail.com"},{"name":"juliangruber","email":"julian@juliangruber.com"},{"name":"dead_horse","email":"dead_horse@qq.com"},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"eivifj","email":"eivind.fjeldstad@gmail.com"},{"name":"aheckmann","email":"aaron.heckmann+github@gmail.com"}],"dist":{"shasum":"91aa03f2888aec0ae2f636f18b0cd95f158510c7","tarball":"http://registry-npm.ywwl.com/koa-conditional-get/download/koa-conditional-get-1.0.3.tgz","integrity":"sha512-I+4NAjm8qaGvM7XCwB4yheIO4xiHStqLSSQ/lsfIkikC/dt7dTPxQu9KwmOr779BnOlQjkCAAYF+X3AYQvOu+Q==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDIgu0mIX/ma+bQul5TJV/rDK40SMUVyCwtFl3bbcaW7AiEAsuZfdrIBWnxlyavnrE4UaHCqbzAIN2BEtjV/b2azvJ4="}],"size":1058,"noattachment":false,"key":"/koa-conditional-get/-/koa-conditional-get-1.0.3.tgz"},"directories":{},"readme":"\n# koa-conditional-get \n\n[![Build Status](https://travis-ci.org/koajs/conditional-get.png)](https://travis-ci.org/koajs/conditional-get)\n\nConditional GET support for koa.\n\n\n## Installation\n\n```bash\n# npm\n$ npm install koa-conditional-get\n# yarn\n$ yarn add koa-conditional-get\n```\n\n\n## Example\n\n```js\nconst conditional = require('koa-conditional-get');\nconst etag = require('koa-etag');\nconst Koa = require('koa');\nconst app = new Koa();\n\n// use it upstream from etag so\n// that they are present\napp.use(conditional());\n\n// add etags\napp.use(etag());\n\n// respond\napp.use(async function(ctx, next){\n  await next();\n\n  ctx.body = {\n    name: 'tobi',\n    species: 'ferret',\n    age: 2\n  };\n})\n\napp.listen(\n  3000,\n  console.log('listening on port 3000')\n)\n```\n\n## License\n\n[MIT](LICENSE)\n","publish_time":1432678467041,"_cnpm_publish_time":1432678467041,"dist-tags":{"latest":"3.0.0","next":"2.0.0","v1":"1.0.4"}}