Skip to main content
Go to Latest
function writeBuffer
import { writeBuffer } from "";

Write to the given file from the given buffer synchronously.

Implements sync part of WriteBuffer in src/ See:


fd: number

file descriptor

buffer: Uint8Array

the data to write

offset: number

where in the buffer to start from

length: number

how much to write

position: number | null

if integer, position to write at in the file. if null, write from the current position

ctx: { errno?: number; }

context object for passing error number