MCPcopy Create free account
hub / github.com/Effect-TS/effect / readDirectoryEntries

Function readDirectoryEntries

packages/platform/deno/src/DenoFileSystem.ts:411–415  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

409}
410
411const readDirectoryEntries = (path: string) =>
412 Effect.map(
413 collectAsyncIterable("readDirectoryEntries", path, () => Deno.readDir(path)),
414 (entries) => entries.map((entry): FileSystem.DirectoryEntry => ({ name: entry.name, type: fileType(entry) }))
415 )
416
417const readFile: FileSystem.FileSystem["readFile"] = (path) =>
418 tryPromise("readFile", path, (signal) => Deno.readFile(path, { signal }))

Callers

nothing calls this directly

Calls 3

collectAsyncIterableFunction · 0.85
fileTypeFunction · 0.70
mapMethod · 0.45

Tested by

no test coverage detected