v2.0.0
π Recursively read directories in Deno
Repository
Current version released
4 years ago
Dependencies
std
Versions
π Recursive Readdir
Recursively read a directory in Deno.
import { recursiveReaddir } from "https://deno.land/x/recursive_readdir/mod.ts";
const files = await recursiveReaddir("path/to/dir"); // string[]
Required permissions:
--allow-read
π‘ Recipes
Search for all markdown files in the content
folder:
import { recursiveReaddir } from "https://deno.land/x/recursive_readdir/mod.ts";
import { join, extname } from "https://deno.land/std/path/mod.ts";
const markdownFiles = (await recursiveReaddir(join(".", "content"))).filter(
(file: string) => extname(file) === ".md"
);
π©βπ» Development
Run tests:
deno test --allow-read
π License
MIT Β© Denorg