touch_grass/file_system/read_directory
Read all the entries in a directory.
Excludes self . and parent ..
The closest syscall is getdents but most other ecosystems use the read directory terminology
- Node.js
fs.readdirSync - In the browser
directoryHandle.entries() - C standard library readdir
This effect includes status information about the returned entries.
Types
Values
pub const decode: fn(value.Value(c, d)) -> Result(
String,
break.Reason(c, d),
)
pub fn encode(
result: Result(List(#(String, Entry)), String),
) -> value.Value(a, b)
pub fn entry() -> isomorphic.Type(a)
A single directory entry, a name and what is at that name.
pub fn lift() -> isomorphic.Type(a)
pub fn lower() -> isomorphic.Type(a)