In WKWebView we can call ObjectiveC/swift code using webkit message handlers
eg: webkit.messageHandlers.<handler>.pushMessage(message)
It works well for simple javascript functions without parameters. But;
Is it possible to call native code with JS callback …
I tried to call a Javascript function from swift using below code but can't access the Javascript function
This is how I create the Javascript context object:
lazy var context: JSContext? = {
let context = JSContext()
guard let
JSPath = Bundle.main.path(…
I'm wondering if it's possible to detect whether a browser is running on iOS, similar to how you can feature detect with Modernizr (although this is obviously device detection rather than feature detection).
Normally I would favour feature detection instead, …