mirror of
https://github.com/tauri-apps/plugins-workspace.git
synced 2026-07-30 17:48:50 +02:00
docs: update README.md and remove allowlist information (#381)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||

|
||||
# Dialog
|
||||
|
||||
<!-- description -->
|
||||
Native system dialogs for opening and saving files along with message dialogs.
|
||||
|
||||
## Install
|
||||
|
||||
@@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file:
|
||||
|
||||
```toml
|
||||
[dependencies]
|
||||
tauri-plugin-dialog = "2.0.0-alpha"
|
||||
# alternatively with Git:
|
||||
tauri-plugin-dialog = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" }
|
||||
```
|
||||
|
||||
@@ -31,6 +33,13 @@ pnpm add @tauri-apps/plugin-dialog
|
||||
npm add @tauri-apps/plugin-dialog
|
||||
# or
|
||||
yarn add @tauri-apps/plugin-dialog
|
||||
|
||||
# alternatively with Git:
|
||||
pnpm add https://github.com/tauri-apps/tauri-plugin-dialog#v2
|
||||
# or
|
||||
npm add https://github.com/tauri-apps/tauri-plugin-dialog#v2
|
||||
# or
|
||||
yarn add https://github.com/tauri-apps/tauri-plugin-dialog#v2
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
@@ -113,11 +113,11 @@ async function open(
|
||||
/**
|
||||
* Open a file/directory selection dialog.
|
||||
*
|
||||
* The selected paths are added to the filesystem and asset protocol allowlist scopes.
|
||||
* The selected paths are added to the filesystem and asset protocol scopes.
|
||||
* When security is more important than the easy of use of this API,
|
||||
* prefer writing a dedicated command instead.
|
||||
*
|
||||
* Note that the allowlist scope change is not persisted, so the values are cleared when the application is restarted.
|
||||
* Note that the scope change is not persisted, so the values are cleared when the application is restarted.
|
||||
* You can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope).
|
||||
* @example
|
||||
* ```typescript
|
||||
@@ -175,11 +175,11 @@ async function open(
|
||||
/**
|
||||
* Open a file/directory save dialog.
|
||||
*
|
||||
* The selected path is added to the filesystem and asset protocol allowlist scopes.
|
||||
* The selected path is added to the filesystem and asset protocol scopes.
|
||||
* When security is more important than the easy of use of this API,
|
||||
* prefer writing a dedicated command instead.
|
||||
*
|
||||
* Note that the allowlist scope change is not persisted, so the values are cleared when the application is restarted.
|
||||
* Note that the scope change is not persisted, so the values are cleared when the application is restarted.
|
||||
* You can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope).
|
||||
* @example
|
||||
* ```typescript
|
||||
|
||||
Reference in New Issue
Block a user