{"name":"raf-loop","version":"1.0.0","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":"542eb24a8c9ecc1f16ae9ad545ed6071e3eb27b4","_id":"raf-loop@1.0.0","_shasum":"e0a13db20d3c2dbf17c3fd2d133014f54632f889","_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":"e0a13db20d3c2dbf17c3fd2d133014f54632f889","tarball":"http://registry-npm.ywwl.com/raf-loop/download/raf-loop-1.0.0.tgz","integrity":"sha512-fTn9IVe+D6PYaT3XtE9zkuTdrthOW/B5cMkDQm9oliHW5ncdWEDOG7ES8ABPCBdkFN5/edCu1+rWUdelM4CaeA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDkRBmY9n9Pw7Pu+HiHO/b8epZeYdJ95q2XZM86dkK2cAiAHJU6m2ejTvxFuJEDL/SB2XrC3hZjYlc/7wEw6YaX92g=="}],"size":2019,"noattachment":false,"key":"/raf-loop/-/raf-loop-1.0.0.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":1417749370372,"_cnpm_publish_time":1417749370372,"dist-tags":{"latest":"1.1.3"}}