How can I define callback functions for WKWebView
in swift?
For UIWebView
I used:
func webViewDidFinishLoad(_ : UIWebView)
{}
And connecting it as delegate
My WKWebView
is defined:
@IBOutlet weak var containerView: UIView!
var wkwebView: WKWebView?
...
self.wkwebView = WKWebView()
self.view = self.wkwebView
You could do this in
navigationDelegate
ofWKWebView
.