Deno.FsFile.prototype.statSync - Deno documentation
method Deno.FsFile.prototype.statSync
FsFile.prototype.statSync(): FileInfo

Synchronously returns a Deno.FileInfo for the file.

import { assert } from "jsr:@std/assert";

using file = Deno.openSync("hello.txt")
const fileInfo = file.statSync();
assert(fileInfo.isFile);

Return Type