nfw

node-file-walker

Node.js module that recursively traversing files/directories

Showing:

Popularity

Downloads/wk

0

GitHub Stars

4

Maintenance

Last Commit

7yrs ago

Contributors

3

Package

Dependencies

0

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Readme

A Simple file/directory traversal module

Build Status

Installation

npm install file-walker

Callback arguments

  • files - an array of files/directories in current directory e.g. ['dummy', 'test.js']
  • dir - directory name e.g. './test'
  • level - Current directory level starting from 0

Example usage

Assume we have the following directory structure

./test/
  +- a.js
  +- b/
     +- c.js
     +- d.js
var walk = require('file-walker');

walk('./directory', function(dir, files, level) {
    // 1st iteration, level = 0, dir = './test', files = ['a.js', 'b']
    // 2nd iteration, level = 1, dir = './test/b', files = ['c.js', 'd.js']
    // your logic
});

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Alternatives

No alternatives found

Tutorials

No tutorials found
Add a tutorial