You can have ad blocking, but you can't have the fast JavaScript engine and ad blocking, unless you are Safari. So you can't have a Chrome or Firefox with both, unless Apple fixes their APIs or allows the "real" versions of those browsers.
Not true at all, and also nothing is stopping you from building your own ad-blocking logic in to your browser either - iCab Mobile for example does just that.
Why not? WKWebView has a delegate callback for the policy to load any given URL. You can implement ad blocking that way. Or you can chose to inject CSS rules if that's your fancy.
Are you referring to the `-[WKWebView navigationDelegate]`?
Thats only used for user initiated navigation, not loading of assets.
You could still inject a JavaScript file or CSS file though to help hide pieces of the view. But that would be content blocking after the HTTP requests have been made.
I don’t know of a way to intercept the HTTP requests as they’re being made from a WKWebView like Safari does for content blocking.
The technical issue is that WKWebView does not honor any custom classes registered with NSURLProtocol (`NSURLProtocol registerClass:`) like UIWebView does, so you don't get to intercept/change/deny every request (not just top-level requests) that the browser makes.