{"_id":"continuable","_rev":"294847","name":"continuable","description":"Idea for callbacks as values","dist-tags":{"latest":"1.2.0"},"maintainers":[{"name":"raynos","email":""}],"time":{"modified":"2021-06-03T18:56:29.000Z","created":"2013-05-02T23:07:31.837Z","1.2.0":"2015-03-15T07:13:27.576Z","1.1.8":"2013-08-13T23:57:00.596Z","1.1.7":"2013-08-13T23:54:58.146Z","1.1.6":"2013-06-06T04:39:09.843Z","1.1.5":"2013-06-05T18:07:57.925Z","1.1.4":"2013-06-02T07:11:26.668Z","1.1.3":"2013-05-27T00:11:16.271Z","1.1.2":"2013-05-26T19:16:38.776Z","1.1.1":"2013-05-26T19:08:59.005Z","1.0.1":"2013-05-23T23:30:47.238Z","0.3.1":"2013-05-23T19:04:44.218Z","0.2.4":"2013-05-23T18:48:48.589Z","0.2.3":"2013-05-17T18:01:38.845Z","0.2.2":"2013-05-15T00:27:35.292Z","0.2.1":"2013-05-02T23:07:31.837Z"},"users":{"jden":true,"jsdnxx":true,"erikvold":true},"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"versions":{"1.2.0":{"name":"continuable","version":"1.2.0","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"gitHead":"f2e2ce2e2ce596a945f784f8942db35a9fbe1e60","_id":"continuable@1.2.0","_shasum":"08277468d41136200074ccf87294308d169f25b6","_from":".","_npmVersion":"1.4.28","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"dist":{"shasum":"08277468d41136200074ccf87294308d169f25b6","size":8985,"noattachment":false,"key":"/continuable/-/continuable-1.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.2.0.tgz"},"directories":{},"publish_time":1426403607576,"_cnpm_publish_time":1426403607576,"_hasShrinkwrap":false},"1.1.8":{"name":"continuable","version":"1.1.8","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.8","dist":{"shasum":"dc877b474160870ae3bcde87336268ebe50597d5","size":7242,"noattachment":false,"key":"/continuable/-/continuable-1.1.8.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.8.tgz"},"_from":".","_npmVersion":"1.3.1","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1376438220596,"_cnpm_publish_time":1376438220596,"_hasShrinkwrap":false},"1.1.7":{"name":"continuable","version":"1.1.7","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.7","dist":{"shasum":"cd0bf6be8a382acbe131d6a489892944b69f5b6b","size":7221,"noattachment":false,"key":"/continuable/-/continuable-1.1.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.7.tgz"},"_from":".","_npmVersion":"1.3.1","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1376438098146,"_cnpm_publish_time":1376438098146,"_hasShrinkwrap":false},"1.1.6":{"name":"continuable","version":"1.1.6","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.6","dist":{"shasum":"6fa1c6ca74b1499062d135b73c943cf24613ec8b","size":6412,"noattachment":false,"key":"/continuable/-/continuable-1.1.6.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.6.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1370493549843,"_cnpm_publish_time":1370493549843,"_hasShrinkwrap":false},"1.1.5":{"name":"continuable","version":"1.1.5","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.5","dist":{"shasum":"f96c86226b53e3325e79eaacd9dd8be622e525bc","size":6190,"noattachment":false,"key":"/continuable/-/continuable-1.1.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.5.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1370455677925,"_cnpm_publish_time":1370455677925,"_hasShrinkwrap":false},"1.1.4":{"name":"continuable","version":"1.1.4","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.4","dist":{"shasum":"17712113b30ac500ab0b13721c4484e66566e4f3","size":5961,"noattachment":false,"key":"/continuable/-/continuable-1.1.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.4.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1370157086668,"_cnpm_publish_time":1370157086668,"_hasShrinkwrap":false},"1.1.3":{"name":"continuable","version":"1.1.3","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.3","dist":{"shasum":"4359a86651603dbf5f87cf56cad379a4c1cd688d","size":5892,"noattachment":false,"key":"/continuable/-/continuable-1.1.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.3.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1369613476271,"_cnpm_publish_time":1369613476271,"_hasShrinkwrap":false},"1.1.2":{"name":"continuable","version":"1.1.2","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.2","dist":{"shasum":"8b871462bb297d9d6eea4f7827dc875fb5a01a96","size":5878,"noattachment":false,"key":"/continuable/-/continuable-1.1.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.2.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1369595798776,"_cnpm_publish_time":1369595798776,"_hasShrinkwrap":false},"1.1.1":{"name":"continuable","version":"1.1.1","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.1.1","dist":{"shasum":"6fdfcd4fc1b23206f52d0460588b3d556f004fb1","size":5877,"noattachment":false,"key":"/continuable/-/continuable-1.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.1.1.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1369595339005,"_cnpm_publish_time":1369595339005,"_hasShrinkwrap":false},"1.0.1":{"name":"continuable","version":"1.0.1","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@1.0.1","dist":{"shasum":"979aa51e4b567a1a02a96dd26f7b23e696ceb774","size":5456,"noattachment":false,"key":"/continuable/-/continuable-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-1.0.1.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1369351847238,"_cnpm_publish_time":1369351847238,"_hasShrinkwrap":false},"0.3.1":{"name":"continuable","version":"0.3.1","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~1.0.2"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@0.3.1","dist":{"shasum":"2b4542cee960d3752da508d489c3335187002b2a","size":5504,"noattachment":false,"key":"/continuable/-/continuable-0.3.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-0.3.1.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1369335884218,"_cnpm_publish_time":1369335884218,"_hasShrinkwrap":false},"0.2.4":{"name":"continuable","version":"0.2.4","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~0.2.2","browserify-server":"~2.1.18","browservefy":"https://github.com/raynos/browservefy/tarball/master","tryme":"https://github.com/raynos/tryme/tarball/master"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js","build-test":"browserify-server --bundle=test/index.js -o test/static/bundle.js --debug","tryme":"tryme ./examples --live","example":"browservefy ./examples/simple.js --browserify='browserify-server' --live --indexed=./examples -- --debug --bundle"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@0.2.4","dist":{"shasum":"d77b9f53caa426ccd00b9df2b8474c0849d11db5","size":5676,"noattachment":false,"key":"/continuable/-/continuable-0.2.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-0.2.4.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1369334928589,"_cnpm_publish_time":1369334928589,"_hasShrinkwrap":false},"0.2.3":{"name":"continuable","version":"0.2.3","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~0.2.2","browserify-server":"~2.1.18","browservefy":"https://github.com/raynos/browservefy/tarball/master","tryme":"https://github.com/raynos/tryme/tarball/master"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js","build-test":"browserify-server --bundle=test/index.js -o test/static/bundle.js --debug","tryme":"tryme ./examples --live","example":"browservefy ./examples/simple.js --browserify='browserify-server' --live --indexed=./examples -- --debug --bundle"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@0.2.3","dist":{"shasum":"e3d6ae3354feacfc344f1f137a3e8e06e4aa4b4b","size":5141,"noattachment":false,"key":"/continuable/-/continuable-0.2.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-0.2.3.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1368813698845,"_cnpm_publish_time":1368813698845,"_hasShrinkwrap":false},"0.2.2":{"name":"continuable","version":"0.2.2","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~0.2.2","browserify-server":"~2.1.18","browservefy":"https://github.com/raynos/browservefy/tarball/master","tryme":"https://github.com/raynos/tryme/tarball/master"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js","build-test":"browserify-server --bundle=test/index.js -o test/static/bundle.js --debug","tryme":"tryme ./examples --live","example":"browservefy ./examples/simple.js --browserify='browserify-server' --live --indexed=./examples -- --debug --bundle"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@0.2.2","dist":{"shasum":"6994edcf6fbb3a7960abdf4da8896dbf292779be","size":4801,"noattachment":false,"key":"/continuable/-/continuable-0.2.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-0.2.2.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1368577655292,"_cnpm_publish_time":1368577655292,"_hasShrinkwrap":false},"0.2.1":{"name":"continuable","version":"0.2.1","description":"Idea for callbacks as values","keywords":[],"author":{"name":"Raynos","email":"raynos2@gmail.com"},"repository":{"type":"git","url":"git://github.com/Raynos/continuable.git"},"main":"index","homepage":"https://github.com/Raynos/continuable","contributors":[{"name":"Raynos"}],"bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"},"dependencies":{},"devDependencies":{"tape":"~0.2.2","browserify-server":"~2.1.18","browservefy":"https://github.com/raynos/browservefy/tarball/master","tryme":"https://github.com/raynos/tryme/tarball/master"},"licenses":[{"type":"MIT","url":"http://github.com/Raynos/continuable/raw/master/LICENSE"}],"scripts":{"test":"node ./test/index.js","build-test":"browserify-server --bundle=test/index.js -o test/static/bundle.js --debug","tryme":"tryme ./examples --live","example":"browservefy ./examples/simple.js --browserify='browserify-server' --live --indexed=./examples -- --debug --bundle"},"testling":{"files":"test/index.js","browsers":["ie/8..latest","firefox/16..latest","firefox/nightly","chrome/22..latest","chrome/canary","opera/12..latest","opera/next","safari/5.1..latest","ipad/6.0..latest","iphone/6.0..latest"]},"readmeFilename":"README.md","_id":"continuable@0.2.1","dist":{"shasum":"b931835c087d7f339af99e8e84a727b03367aa9e","size":4781,"noattachment":false,"key":"/continuable/-/continuable-0.2.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/continuable/download/continuable-0.2.1.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"raynos","email":"raynos2@gmail.com"},"maintainers":[{"name":"raynos","email":""}],"directories":{},"publish_time":1367536051837,"_cnpm_publish_time":1367536051837,"_hasShrinkwrap":false}},"readme":"# continuable\n\n[![build status][1]][2] [![dependency status][3]][4]\n\n[![browser support][5]][6]\n\nIdea for callbacks as values\n\n## Example\n\n```js\nvar readFile = function (uri) {\n    return function (cb) {\n        fs.readFile(uri, cb)\n    }\n}\n\nfunction map(source, lambda) {\n    return function continuable(callback) {\n        source(function (err, value) {\n            callback(err, err ? null : lambda(value))\n        })\n    }\n}\n\nvar asString = map(readFile(\"/tmp/foo.json\"), String)\nvar asJSON = map(asString, function (x) { return JSON.parse(x) })\n\nasJSON(function (err, value) {\n    /* do stuff with JSON */\n})\n```\n\n## Docs\n\n### `Continuable(callback)`\n\n```js\ntype Continuable := (callback:(Error, Value) => void) => void\n```\n\nA continuable is simply a function that takes a single argument, a callback.\nThe callback get's called with the normal node error and value pattern.\n\n```js\n// readFile := (String) => Continuable<Buffer>\nvar readFile = function (uri) {\n    return function continuable(callback) {\n        fs.readFile(uri, callback)\n    }\n}\n```\n\nThe reason to have a continuable instead of passing a callback directly into\nanother value is that a continuable is a concrete value that can be returned.\n\nWhich means you can call useful functions on this value like `map` and `join`\n\n### `to(asyncFunction)`\n\ntake an async function and return a function that works as async function or continuable.\n\n``` js\nvar readFile = continuable.to(fs.readFile)\n\nreadFile (path, 'utf8') (function (err, text) {\n  //there you go\n})\n```\n\n### `map(source, lambda)`\n\n```js\nmap := (source:Continuable<A>, lambda:(A) => B) => Continuable<B>\n```\n\nmap takes a transformation function and a continuable and returns a new\ncontinuable. The new continuable is the value of the first continuable\ntransformed by your mapping function.\n\n```js\nvar asString = map(readFile(\"/tmp/foo.json\"), String)\nvar asJSON = map(asString, function (x) { return JSON.parse(x) })\n\nasJSON(function (err, json) {\n    /* do stuff */\n})\n```\n\n### `mapAsync(source, lambda)`\n\n```ocaml\nmapAsync := (source: Continuable<A>, lambda: (A, Callback<B>))\n    => Continuable<B>\n```\n\nmapAsync takes an asynchronous transformation function and a source\ncontinuable. The new continuable is the value of the first continuable\npassed through the async transformation.\n\n```js\nvar asString = map(readFile(\"/tmp/foo.json\"), String)\nvar asJSON = map(asString, function (x) { return JSON.parse(x) })\n\nvar written = mapAsync(asJSON, function (json, cb) {\n    fs.writeFile(\"/tmp/bar.json\", JSON.stringify(json), cb)\n})\n\nwritten(function (err, writeResult) {\n    /* stuff */\n})\n```\n\n### `join(continuable)`\n\n```js\njoin := (source:Continuable<Continuable<T>>) => Continuable<T>\n```\n\n`join` takes a continuable that contains another continuable and flattens it by\none layer. This is useful if you return another asynchronous operation from\n`map`\n\n```js\nvar asString = map(readFile(\"/tmp/foo.json\"), String)\nvar asJSON = map(asString, function (x) { return JSON.parse(x) })\n\nvar write = map(asJSON, function (json) {\n    return function continuable(cb) {\n        fs.writeFile(\"/tmp/bar.json\", JSON.stringify(json), cb)\n    }\n})\n\njoin(write)(function (err, writeResult) {\n    /* stuff */\n})\n```\n\n### `both(source)`\n\n```ocaml\ncontinuable := (Continuable<A>) => Continuable<[Error, A]>\n```\n\n`both` takes a continuable and returns a continuable containing a tuple of\n    the error and the value. The returned continuable will never contain an\n    error.\n\nThis is useful for handling errors using if statements\n\n```js\nvar fileOrNull = function (uri) {\n    var source = fs.readFile.bind(null, uri)\n    var maybeFile = both(source)\n\n    return map(maybeFile, function (err, tuple) {\n        if (tuple[0]) {\n            return null\n        }\n\n        return tuple[1]\n    })\n}\n```\n\n### `of(value)`\n\n```js\nof := (Value) => Continuable<Value>\n```\n\n`of` takes any value and returns a Continuable for this value. This is useful\n    if you want to implement a function that either returns a value or a\n    continuable.\n\n```js\nfunction getThing() {\n    var thing = localStorage.getItem(\"thing\")\n\n    if (thing) return of(thing)\n\n    return ajax(\"/thing\")\n}\n```\n\n### `error(err)`\n\n```js\nerror := (Error) => Continuable<void>\n```\n\n`error` takes any error and returns a Continuable that will return said error.\n    This is useful if you want to transform a normal continuable into an\n    error state one.\n\n```js\nvar body = getBody(req, res)\n\nvar dbWrite = map(body, function (body) {\n    if (!body) {\n        return error(new Error(\"Need body\"))\n    }\n\n    return db.write(body)\n})\n\njoin(dbWrite)(function (err, writeResult) {\n    /* do stuff */\n})\n```\n\n### `chain(continuable, lambda)`\n\n```js\nchain := (Continuable<A>, (A) => Continuable<B>) => Continuable<B>\n```\n\n`chain` takes a lambda function that is given the value and returns another\n    continuables. The result will be a continuable given the value of the\n    returned continuable.\n\nIn combination with `of` this makes `Continuable` a monad.\n\nAlternatively this can be seen as sugar for `map` followed by `join`\n\n```js\nvar body = getBody(req, res)\n\nvar dbWrite = chain(body, function (body) {\n    if (!body) {\n        return error(new Error(\"Need body\"))\n    }\n\n    return db.write(body)\n})\n\ndbWrite(function (err, writeResult) {\n    /* do stuff */\n})\n```\n\n### `either(continuable, left, right?)`\n\n```js\neither := (source: Continuable<A>,\n           left: (Error, cb: Callback<B>) => Continuable<B>,\n          right?: (A) => Continuable<B>)\n    => Continuable<B>\n```\n\n`either` takes a source continuable and a left and right function.\n    It will either call the left function with the error in source\n    or call the right function with the value in the source.\n\nThe returned continuable will contain the value returned from\n    either left or right. Note that left and right return\n    continuables themself.\n\n```js\nvar fs = require(\"fs\")\nvar either = require(\"continuable/either\")\n\nvar fileStat = fs.stat.bind(null, \"./package.json\")\nvar fileExists = either(fileStat, function left(err) {\n    return fs.writeFile.bind(null, \"./package.json\", \"{}\")\n}) // note the right function is optional\n\nvar file = chain(fileExists, function () {\n    return fs.readFile.bind(null, \"./package.json\")\n})\n\nfile(function (err, body) {\n    // There is no error because we create an empty file if the\n    // stat failed. Body is either body or {}\n})\n```\n\nThe left function can either return a Continuable or call the\n    passed callback directly. For example:\n\n```js\nvar item = fs.stat.bind(null, \"./file\")\nvar maybeItem = either(item, function left(err, cb) {\n    if (err.code === \"ENOENT\") {\n        return cb(null, null)\n    }\n\n    cb(err)\n})\n\nmaybeItem(function (err, item) {\n    // if stat returns a file not found then item is null\n    // if stat returns a random disk error then error!\n    // if stat returns the stat then item!\n})\n```\n\nUsing the callback form is convenient and avoids the usage of\n    return `return of(null)` and `return error(err)`\n\n## `series([continuables])`\n\nSee [continuable-series][7]\n\nGiven an array of continuables return a continuable that invokes them in order,\nor until one errors.\n\n## `para([continuables])`\n\nSee [continuable-para][8]\n\nGiven an array on continuables return a continuable\n\n## Installation\n\n`npm install continuable`\n\n## Contributors\n\n - Raynos\n\n## MIT Licenced\n\n  [1]: https://secure.travis-ci.org/Raynos/continuable.png\n  [2]: https://travis-ci.org/Raynos/continuable\n  [3]: https://david-dm.org/Raynos/continuable.png\n  [4]: https://david-dm.org/Raynos/continuable\n  [5]: https://ci.testling.com/Raynos/continuable.png\n  [6]: https://ci.testling.com/Raynos/continuable\n  [7]: http://ghub.io/continuable-series\n  [8]: http://ghub.io/continuable-para\n","_attachments":{},"homepage":"https://github.com/Raynos/continuable","bugs":{"url":"https://github.com/Raynos/continuable/issues","email":"raynos2@gmail.com"}}