Skip to content
Discussion options

You must be logged in to vote

I'm not sure what you mean with a listener in this context. So if my generic answer doesn't help, please provide examples for what you mean/what you tried.

In general though, there's no JS equivalent to tauri's invoke/command system (to call rust commands from js).
Instead you either have to use an emit/listen combination (events), or use window.eval() if your js side is in global scope (for example on the js window var), example: window.eval("window.myFunction('something')") (to be clear, the first window is in rust, the second one in js)

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by AsynchronousAI
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #8595 on January 14, 2024 14:33.