I am not getting proper understanding of what is the main adavantage of using SFSafariViewController, if we are using [[UIApplication sharedApplication] openUrl: strUrl];
What are the difference between both?
SFSafariViewController no longer shares cookies with the standalone Safari browser. Thus, a website can no longer determine that the user on SFSafariViewController is the same user on Safari, even though the view controller and the browser are open on the same device.
Unlike UIWebView, which does not support server authentication challenges, WKWebView does. In practical terms, this means that when using WKWebView, you can enter site credentials for password-protected websites.
WKWebView. WKWebView was introduced in iOS 8 allowing app developers to implement a web browsing interface similar to that of mobile Safari. This is due, in part, to the fact that WKWebView uses the Nitro Javascript engine, the same engine used by mobile Safari.
With SFSafariViewController, you can use nearly all of the benefits of viewing web content inside Safari without forcing users to leave your app.
The majority of apps just need to provide a generalized web viewing experience. This is the perfect scenario for the safari view controller.
Before SFSafariViewController, the browsing experience was inconsistent across different apps, which may confuse the user. Some interfaces may also lack the things users expect, such as a progress bar indicating how much of the page is loaded. You don't have access to all of Safari's features. This includes the reader view, the iCloud keychain for autofill capabilities, and more.
If you wanted to have those features before iOS 9, you were forced to have the user leave your app entirely by opening the content inside Safari. SFSafariViewController
solves every one of these problems.
For more see here
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With