pub fn open_path<P: AsRef<Path>, S: AsRef<str>>(
path: P,
with: Option<S>,
) -> Result<(), Error>Expand description
Opens path with the program specified in with, or system default if None.
§Platform-specific:
- Android / iOS: Always opens using default program.
§Examples
tauri::Builder::default()
.setup(|app| {
// open the given URL on the system default explorer
tauri_plugin_opener::open_path("/path/to/file", None::<&str>)?;
Ok(())
});