Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/deno/cli/js/io.ts>Writer

A modern runtime for JavaScript and TypeScript.
Go to Latest
interface Writer
import { type Writer } from "https://deno.land/x/deno@v0.28.0/cli/js/io.ts";

Methods

write(p: Uint8Array): Promise<number>

Writes p.byteLength bytes from p to the underlying data stream. It resolves to the number of bytes written from p (0 <= n <= p.byteLength) and any error encountered that caused the write to stop early. write() must return a non-null error if it returns n < p.byteLength. write() must not modify the slice data, even temporarily.

Implementations must not retain p.