WriteFileOptions
import { WriteFileOptions } from "jsr:@ende/fs/unstable-types";interface ยท experimental
interface WriteFileOptionsOptions for writing to a file.
Properties
append
append?: booleanIf set to true, will append to a file instead of overwriting previous
contents.
Default: false
create
create?: booleanSets the option to allow creating a new file, if one doesn't already exist at the specified path.
Default: true
createNew
createNew?: booleanIf set to true, no file, directory, or symlink is allowed to exist at
the target location. When createNew is set to true, create is ignored.
Default: false
mode
mode?: numberPermissions always applied to file.
signal
signal?: AbortSignalAn abort signal to allow cancellation of the file write operation.
If the signal becomes aborted the write file operation will be stopped
and the promise returned will be rejected with an AbortError.