MCPcopy Index your code
hub / github.com/angular/angular-cli / exists

Function exists

packages/angular_devkit/core/node/host.ts:27–35  ·  view source on GitHub ↗
(path: PathLike)

Source from the content-addressed store, hash-verified

25import { Path, PathFragment, dirname, fragment, getSystemPath, normalize, virtualFs } from '../src';
26
27async function exists(path: PathLike): Promise<boolean> {
28 try {
29 await fsPromises.access(path, constants.F_OK);
30
31 return true;
32 } catch {
33 return false;
34 }
35}
36
37// This will only be initialized if the watch() method is called.
38// Otherwise chokidar appears only in type positions, and shouldn't be referenced

Callers 1

existsMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected