1.0.3 • Published 1 year ago

speedload v1.0.3

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

speedload

A Zero-dependency, asynchronous, and fast tool for recursively loading files (by a given extension) from a directory tree into a convenient, flat array.

Install

npm i speedload

Example Usage

const { join } = require("node:path");
const { getFiles } = require("speedload");
const ext = ".js";
const path = join(__dirname, "../");

getFiles(ext, path, (results, info) => {
  console.log(results, info);
});

Notice

It's most likely not production-ready, but could be useful in specific cases

To-Do

Add more features and refactor a lot