function readAllSync
readAllSync(reader: ReaderSync): Uint8ArraySynchronously reads ReaderSync r until EOF (null) and returns
the content as Uint8Array.
Examples
Example 1
Example 1
import { readAllSync } from "@std/io/read_all"; // Example from stdin const stdinContent = readAllSync(Deno.stdin); // Example from file using file = Deno.openSync("my_file.txt", {read: true}); const myFileContent = readAllSync(file);
Parameters
reader: ReaderSync