deno / 1.23.2 / ~ / deno.create.html /

Deno.create

Creates a file if none exists or truncates an existing file and resolves to an instance of Deno.FsFile.

const file = await Deno.create("/foo/bar.txt");

Requires allow-read and allow-write permissions.

function create( path: string | URL) : Promise<FsFile>;
create( path: string | URL) : Promise<FsFile>

Parameters

path: string | URL

Return Type

Promise<FsFile>

© 2018–2022 the Deno authors
https://doc.deno.land/deno/stable/~/Deno.create