Using EvaluteJS for listening to events

I have a problem with listening to event from using the EvaluteJS. What i want to do is communicate with the webview back and forth.

What i want to do is create a video player in the webview and keep track of the video it’s current time. But using the EvaluteJS it seems you can only return static properties.

Is there a way to listen to events from the webview (like window.addEventListener(“message”)) and do something with it on the fuse side? And also execute functions of the webview outside of eveluate?

I assume this isn’t possible…?

Hi Franklin, unfortunately this is currently not possible. EvaluateJS is capable of executing code on the webview context but doesn’t create further bindings back into the Fuse context. There are some (sort of lame) ways to do this like periodic polling of properties via EvaluateJS but no event bindings can currently be created.