5.0.0
Note: fdir follows semantic versoning hence this release is not backward compatible with any previous release.
Breaking Changes
- Filters applied using
new fdir().filter()are now joined via AND instead of OR. (#35)
Features
- There is now a brand new
onlyDirsbuilder function that allows you to grab (and filter) only directories ignoring all files. (#43)
const crawler = new fdir().onlyDirs();- As a result, filters now work with directories as well and include
isDirectoryas second parameter to.filter()function:
const crawler = new fdir()
.filter((path, isDirectory) => path.startsWith("."))
.filter((path, isDirectory) => path.endsWith(".js"));- Full path of the directory is now sent to the
excludeFnof.exclude(excludeFn): (#46)
const crawler = new fdir().exclude((dirName, dirPath) =>
dirName.startsWith(".")
);