функция Deno.stat
stat(path: string | URL): Promise<FileInfo>Возвращает Deno.FileInfo для указанного path. Всегда следует за символичными ссылками.
import { assert } from "jsr:@std/assert";
const fileInfo = await Deno.stat("hello.txt");
assert(fileInfo.isFile);
Требует разрешения allow-read.
Параметры
path: string | URL Тип возвращаемого значения
Promise<FileInfo>
© 2018–2024 the Deno authors
Licensed under the MIT License.
https://docs.deno.com/api/deno/~/Deno.stat