How can we find UIWebView in Project and replace it with WKWebView?

12,970

I solved a similar problem as follows:

  1. Search in the workspace UIWebView and replace it with WKWebView

  2. Remove UIWebView in the storyboards and add "WKWebView" instead (do not forget about the connection with the code)

  3. In the terminal, in the project folder, enter the command:

    grep -r "UIWebView" .

    (don't forget the space and the dot at the end of command!) to find links to UIWebView in library files.

  4. Update the libraries with UIWebView, and if it does not help, then delete all libraries that have links to UIWebView. (Most libraries with UIWebView have new updates without UIWebView.)

Share:
12,970
Akshay Phulare
Author by

Akshay Phulare

Updated on July 23, 2022

Comments

  • Akshay Phulare
    Akshay Phulare almost 2 years

    We got this email from [email protected] while uploading a build:

    We identified one or more issues with a recent delivery for your app, "App Name" 1.0 (5.0). Please correct the following issues, then upload again.

    ITMS-90809: Deprecated API Usage - New apps that use UIWebView are no longer accepted. Instead, use WKWebView for improved security and reliability. Learn more (https://developer.apple.com/documentation/uikit/uiwebview).

    Best regards,

    The App Store Team

    I've not used UIWebView in my project. I've updated all pods. I searched word 'UIWebView' in the workspace, but nothing was found. I also searched in the terminal using grep -r -f "UIWebView"., getting grep: UIWebView.: No such file or directory.

    What should I do before uploading a new build?

  • Warif Akhand Rishi
    Warif Akhand Rishi almost 4 years
    step 3 for Binary files 👍
  • Ville Miekk-oja
    Ville Miekk-oja almost 4 years
    Property 'delegate' not found on object of type 'WKWebView', error after replacing UIWebView in React.xcodeproj