Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/olekenneth/node-readdir-recursive-promise

Read directory and return promise or directory object with files
https://github.com/olekenneth/node-readdir-recursive-promise

javascript nodejs promise readdir

Last synced: about 2 months ago
JSON representation

Read directory and return promise or directory object with files

Awesome Lists containing this project

README

        

# About readdir-recursive-promise
Read directory and return promise or directory object with files

# Install
`npm install --save readdir-recursive-promise`

# Examples

## Return promise
```javascript
var rdr = require('readdir-recursive-promise');

rdr.readdirAsync('directory').then(function(res) {
console.log(res);
});
```

## Normal callback
```javascript
var rdr = require('readdir-recursive-promise');

rdr.readdir('directory', function(err, res) {
console.log(err, res);
});
```