Function tauri_sys::fs::exists

source ·
pub async fn exists(path: &Path, dir: BaseDirectory) -> Result<bool, Error>
Expand description

Checks if a path exists.

§Example

use tauri_sys::fs;

let file_exists = fs::exists(path, BaseDirectory::Download).expect("could not check if path exists");

Requires allowlist > fs > exists to be enabled.