Tauri Commands Async Patterns

Use when writing async Tauri v2 commands — deciding when a command should be `async fn`, spawning background tasks that outlive the command via `tokio::spawn` + cloned `AppHandle`, cancellable long-running work with `tokio::select!` + `CancellationToken`, streaming progress via `Channel` instead of polling, and avoiding deadlock anti-patterns (std-mutex across `.await`, holding guards across awaits).

stuffbucket 74c93e3 2 files · 10.0 KB Updated

File contents

stuffbucket/skills/tree/main/plugins/stuffbucket/skills/tauri-commands-async-patterns commit 74c93e352a

Frequently asked questions

npx skillmds@latest add stuffbucket/tauri-commands-async-patterns