Expand description
The RPC module includes utilities to send messages to the JS layer of the webview.
Functionsยง
- format_
callback - Formats a function name and argument to be evaluated as callback.
- format_
callback_ result - Formats a Result type to its Promise response.
Useful for Promises handling.
If the Result
is_ok()
, the callback will be thesuccess_callback
function name and the argument will be the Ok value. If the Resultis_err()
, the callback will be theerror_callback
function name and the argument will be the Err value.