Name Last Update
..
test Loading commit data...
.npmignore Loading commit data...
History.md Loading commit data...
Makefile Loading commit data...
Readme.md Loading commit data...
index.js Loading commit data...
package.json Loading commit data...

thunkify

Turn a regular node function into one which returns a thunk, useful for generator-based flow control such as co.

Installation

$ npm install thunkify

Example

var thunkify = require('thunkify');
var fs = require('fs');

var read = thunkify(fs.readFile);

read('package.json', 'utf8')(function(err, str){

});

License

MIT