es6-promisify-all
v0.1.0
Published
Promisify entire objects
Downloads
39
Maintainers
Readme
es6-promisify-all
Promisify entire objects.
Installation
npm install --save es6-promisify-all
Usage
var promisifyAll = require('es6-promisify-all');
var fs = promisifyAll(require('fs'));
fs.readFileAsync('myfile.js', 'utf8')
.then(function(contents) {
console.log(contents);
})
.catch(function(e) {
console.error(e.stack);
});