UNPKG

elliotisms

Version:

reusable atomic functions for the dumb shit i reuse all the time. only about half are jokes.

10 lines (9 loc) 310 B
import { fdir } from "fdir" const fdirQuery = async (absoluteDirectory, directoriesIncluded = false) => { let files = new fdir().withFullPaths().crawl(absoluteDirectory) if (directoriesIncluded === true) { files = files.withDirs() } let fileOutput = await files.withPromise() return fileOutput }