Closed jun1st closed 8 years ago
The webView:didCommitNavigation
and webView:didFinishNavigation
would only get called on the initial "cold boot" request, which by the time sessionDidLoadWebView
is called, would have already completed. All other requests are handled by Turbolinks in JavaScript using xhr, so they don't hit the WKNavigationDelegate
load methods.
Your best bet is to add a JavaScript event handler to listen to turbolinks:request-end
to access the response headers - https://github.com/turbolinks/turbolinks#full-list-of-events.
I'd like get some data from response headers, I think it's inside WKNavigation object. But my custom delegate not get called.
I've set my view controller as the delegate
here is the summary of my delegate
the
decidePolicyForNavigationAction
method did get called, but not the other two,Did I miss anything?