0

This post resolve how to clear cookie for WKWebView.

But the -[WKWebsiteDataStore removeDataOfTypes:] API only clear cookies when there is a WKWebView alive.

This is problematic because WKWebViews can be deallocated at any time during the app's lifecycle and this API should not be dependent on that.

There is a bug reported in WebKit website : https://bugs.webkit.org/show_bug.cgi?id=149078 (which has an app demo)

But no solution yet. Any Help?

Community
  • 1
  • 1
Andrew
  • 1,078
  • 9
  • 21

1 Answers1

0

Just use another WKProcessPool after clear cookies, and no cache any more.

Andrew
  • 1,078
  • 9
  • 21