The below category that uses private API usually found in Safari lets WkWebView enable Application cache
@interface WKPreferences (MyPreferences)
- (void)_setOfflineApplicationCacheIsEnabled:(BOOL)offlineApplicationCacheIsEnabled;
@end
I wanted to implement application cache using Swift so I made the conversion of above code
extension WKPreferences {
func _setOfflineApplicationCacheIsEnabled(offlineApplicationCacheIsEnabled: Bool) {
}
}
But in swift its not working.
Here is the sample url that has application cache.I tried this in safari it works perfectly but not in WkWebView