stdweb icon indicating copy to clipboard operation
stdweb copied to clipboard

Feature Idea: Implementation of CustomEvent?

Open mbuscemi opened this issue 4 years ago • 0 comments

I've been working on setting up bi-directional communication between an app's Webview and Yew (stdweb-based) layers. Getting messages from Webview back into Yew was particularly challenging. With help from the maintainer of Webview, I eventually found a solution using the CustomEvent API in JS.

I got this to work on the Yew/stdweb layer using a js! block. However, small typos in JavaScript code yield obscure errors. I would prefer to utilize something document().add_event_listener( ... ). However, there does not appear to be a CustomEvent implementation for stdweb.

I would be happy to work on contributing that, if there is a desire for it.

mbuscemi avatar Apr 17 '20 10:04 mbuscemi