Skip to content

exists

Module @netwiv/api/plugins/fs · Kind Function

import { exists } from '@netwiv/api/plugins/fs';

Check if a path exists.

function exists(path: string | URL, options?: ExistsOptions | undefined): Promise<boolean>
import { exists, BaseDirectory } from '@netwiv/api/plugins/fs';
// Check if the `$APPDATA/avatar.png` file exists
await exists('avatar.png', { baseDir: BaseDirectory.AppData });

Upstream since 2.0.0


Descriptions come from the pinned @tauri-apps/plugin-fs@2.5.2 declarations (MIT OR Apache-2.0); imports are shown with @netwiv/api paths.