Typed wrappers around every Tauri event emitted by the Rust plugin.
The Rust plugin uses tauri-specta v2 EventCollection to register events
so their names and payload shapes are type-safe on both sides. These TS
wrappers subscribe to those events and apply the appropriate graph store
mutations, keeping the TS store in sync with Rust-side state changes.
Returned unsubscribe handles should be called on component/plugin teardown
to avoid memory leaks.
events.ts
Typed wrappers around every Tauri event emitted by the Rust plugin.
The Rust plugin uses tauri-specta v2
EventCollectionto register events so their names and payload shapes are type-safe on both sides. These TS wrappers subscribe to those events and apply the appropriate graph store mutations, keeping the TS store in sync with Rust-side state changes.Returned unsubscribe handles should be called on component/plugin teardown to avoid memory leaks.