WebView is used to display web content in your iOS applications.Yesterday, React Native announced a new native iOS backend to the WebView component that uses WKWebView. This WebView component will be available in the upcoming React Native 0.57 release.
Apple has discouraged the use of UIWebViews for a long time. This is due to its being formally deprecated in the upcoming months. It is advised that you use the WKWebView class instead of using UIWebView for the apps that run in iOS 8 and above.
You can use the useWebKit property to opt into this implementation:
Earlier, to embed web content in our applications we had two options, UIWebView and WKWebView.
UIWebView is the original WebView introduced in 2.0. It is known to have some pitfalls and problems. The main drawback is that it has no legitimate way to facilitate communication between the JavaScript running in the WebView and React Native. The newly introduced WKWebView aims to solve this problem. Other benefits of WKWebView over UIWebView include faster JavaScript execution and a multi-process architecture.
You must avoid using the following properties, for the time being:
Per React Native community, WKWebView doesn't support the scalesPageToFit property. Hence, they couldn't implement this on the WebView React Native component.
To know more about the new WebViews, check out their announcement on React Native’s official website and their GitHub repository.
Apple releases iOS 12 beta 2 with screen time and battery usage updates among others
React Native 0.56 is now available
Apple releases iOS 11.4 update with features including AirPlay 2, and HomePod among others