MCPcopy Create free account
hub / github.com/denoland/std / pathExists

Function pathExists

fs/unstable_write_file_test.ts:30–37  ·  view source on GitHub ↗
(path: string | URL)

Source from the content-addressed store, hash-verified

28}
29
30function pathExists(path: string | URL): boolean {
31 try {
32 statSync(path);
33 return true;
34 } catch {
35 return false;
36 }
37}
38
39Deno.test("writeFile() writes to a file", async () => {
40 const tempDirPath = await makeTempDir({ prefix: "writeFile_" });

Callers 1

assertMissingFunction · 0.70

Calls 1

statSyncFunction · 0.90

Tested by

no test coverage detected