mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-08-26 05:14:11 +02:00
Add a typed platform package to decouple the frontend from Tauri (#539)
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
0068be9ffc
commit
2383f06e71
@@ -1,9 +1,9 @@
|
||||
import { event } from "@tauri-apps/api";
|
||||
import { platform } from "@yaakapp-internal/platform";
|
||||
import { useFastMutation } from "./useFastMutation";
|
||||
|
||||
export function useCancelHttpResponse(id: string | null) {
|
||||
return useFastMutation<void>({
|
||||
mutationKey: ["cancel_http_response", id],
|
||||
mutationFn: () => event.emit(`cancel_http_response_${id}`),
|
||||
mutationFn: () => platform.emit(`cancel_http_response_${id}`),
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user