I would like to now if there are some equivalent of addJavascriptInterface()
from Android
in UWP
. From what I have read, first the script must be invoke through the method InvokeScript
and in the JavaScript
function window.external.notify()
must be called. But I don´t want to invoke the javascript function, I just want to “wait” until the javaScriptFunction is called,. It would be like a listener of Javascript functions. Is this possible?
Advertisement
Answer
Finally I found what I wanted, this is the solution, use the WebView.AddWebAllowedObject
method.