mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2025-11-25 18:26:28 -05:00
feat(cli+tauri): Send logs from host to guest (#90)
* feat(tauri): send logs from cli to tauri --------- Co-authored-by: binarybaron <binarybaron@unstoppableswap.net> Co-authored-by: binarybaron <86064887+binarybaron@users.noreply.github.com>
This commit is contained in:
parent
21608ce4f7
commit
7b79ad6abe
14 changed files with 206 additions and 136 deletions
|
|
@ -5,6 +5,7 @@ import {
|
|||
BalanceResponse,
|
||||
BuyXmrArgs,
|
||||
BuyXmrResponse,
|
||||
CliLogEmittedEvent,
|
||||
GetLogsArgs,
|
||||
GetLogsResponse,
|
||||
GetSwapInfoResponse,
|
||||
|
|
@ -20,6 +21,7 @@ import {
|
|||
} from "models/tauriModel";
|
||||
import {
|
||||
contextStatusEventReceived,
|
||||
receivedCliLog,
|
||||
rpcSetBalance,
|
||||
rpcSetSwapInfo,
|
||||
} from "store/features/rpcSlice";
|
||||
|
|
@ -47,6 +49,11 @@ export async function initEventListeners() {
|
|||
console.log("Received context init progress event", event.payload);
|
||||
store.dispatch(contextStatusEventReceived(event.payload));
|
||||
});
|
||||
|
||||
listen<CliLogEmittedEvent>("cli-log-emitted", (event) => {
|
||||
console.log("Received cli log event", event.payload);
|
||||
store.dispatch(receivedCliLog(event.payload))
|
||||
})
|
||||
}
|
||||
|
||||
async function invoke<ARGS, RESPONSE>(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue