Skip to content

Get all files from a directory including files within subdirectories.

License

Notifications You must be signed in to change notification settings

stranothus/dirflat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dirflat

dirflat is a very basic function to recursively fetch all files in a directory, including sub-directories.

File structure:

.
+-- foo.txt
+-- bar.js
+-- index.js
+-- _test
|   +-- foo.js
|   +-- bar.txt

index.js

const dirFlat = require("dirflat");

dirFlat("./").then(console.log);
// ouputs ["./foo.txt", "./bar.js", "./index.js", "./test/foo.js", "./test/bar.txt"]

About

Get all files from a directory including files within subdirectories.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published