{"name":"raf-loop","version":"1.0.1","description":"a minimal requestAnimationFrame render loop","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{"events":"^1.0.2","inherits":"^2.0.1","raf":"^2.0.4","right-now":"^1.0.0"},"devDependencies":{"tape":"^3.0.3"},"scripts":{"test":"node test.js"},"keywords":["raf","request","animation","frame","requestAnimationFrame","loop","game","render","2d"],"repository":{"type":"git","url":"git://github.com/mattdesl/raf-loop.git"},"homepage":"https://github.com/mattdesl/raf-loop","bugs":{"url":"https://github.com/mattdesl/raf-loop/issues"},"gitHead":"bf5dd42ed0ddc6458b23782a662341d1673c0402","_id":"raf-loop@1.0.1","_shasum":"c823588b36980598b47d1f55a0d02a95219c4196","_from":".","_npmVersion":"2.1.4","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}],"dist":{"shasum":"c823588b36980598b47d1f55a0d02a95219c4196","tarball":"http://registry-npm.ywwl.com/raf-loop/download/raf-loop-1.0.1.tgz","integrity":"sha512-ge16u53E110rdsUKqblqsZrk+EhW0KXmYatH9MsuOnGdHSQM43xfgPSgt0jCBxLsD4QufrlLvo4esOC3str2xw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC0RwiwTYiMdEeFk8fSnvLPlMWaUvASbCEAWfhA6Xpc0AIgfOu/bqb3acrxT2Uom1UDiZCHFQxCreoe23zpWyWAE6U="}],"size":2019,"noattachment":false,"key":"/raf-loop/-/raf-loop-1.0.1.tgz"},"directories":{},"readme":"# raf-loop\n\n[![stable](http://badges.github.io/stability-badges/dist/stable.svg)](http://github.com/badges/stability-badges)\n\nA minimal requestAnimationFrame render loop for node and the browser, using high-performance timing where possible.\n\n```js\nvar loop = require('raf-loop')\n\nvar engine = loop(function(dt) {\n    // delta time in milliseconds \n}).start()\n```\n\n## Usage\n\n[![NPM](https://nodei.co/npm/raf-loop.png)](https://nodei.co/npm/raf-loop/)\n\n#### `engine = loop([fn])`\n\nCreates a new loop with an optional function to receive tick events. The function will be called with delta time as the first parameter, in milliseconds.\n\n#### `engine.start()`\n\nStarts the render loop and returns this engine, for chaining.\n\n#### `engine.stop()`\n\nStops the render loop and cancels the currently requested animation frame.\n\n#### `engine.on('tick', fn)`\n\nAttaches another function to the render loop.\n\n## License\n\nMIT, see [LICENSE.md](http://github.com/mattdesl/raf-loop/blob/master/LICENSE.md) for details.\n","publish_time":1417749758087,"_cnpm_publish_time":1417749758087,"dist-tags":{"latest":"1.1.3"}}