WebKit's fast tap functionality has come to Safari in iOS 9.3 (see documentation). I work on an e-reader app that uses a web view to display text. We still use UIWebView because of various bugs in WKWebView, but I can switch out to WKWebView very easily for testing purposes. We have our own custom touch handling to get around the 350 ms touch delay so links feel faster. I just tried out the fast-tap thing, and it only appears to work in WKWebView. Is this correct / confirmed / documented somewhere? Or should fast-tap work in both UIWebView and WKWebView?
Update: here is an article about some changes toward the current fast-tap behavior in iOS 8 that only appeared in WKWebView. But nothing about the new iOS 9.3 stuff.
Related
Here is the AR Quick Look website from Apple docs - https://developer.apple.com/augmented-reality/quick-look/
If I go to this website in the Safari browser on my iPhone 8, then everything is working correctly. I can tap any of the 3D model and place it inside the Augmented Reality.
However, if I view the same website in the WKWebView, then the AR models are not working correctly. I am not able to tap any model and place it inside the AR.
For the comparison I am attaching screenshots from the Safari browser and from the WKWebView
Safari
WKWebView
As you can see in WKWebView, the AR icon is not even showing up.
Does anyone knows why AR images are not working inside the WKWebView?
I will be very glad for any help.
I just found a tweet from 2018 suggesting that WKWebView does not support AR Quick Look. You can find it here. The WebKit website also suggests that.
Most probably SFSafariController should be used instead.
I am starting learn webview in ios swift but i am unable to understand the difference between uiwebview and webview kit. recommend some article or documentation so that i can make it clear.
UIWebView is deprecated and should not be used in apps and WKWebView is the replacement for that .
If you compare it performance wise, WKWebView outperforms UIWebView in case of memory consumption as UIWebView consumes a lot of memory to load the same webpage and WKWebView on the other hand does not consume that much. You can easily create a demo app and see for yourself
As per Apple Documentation
In apps that run in iOS 8 and later, use the WKWebView class instead
of using UIWebView
So, to sum it up, if you want to load a webpage inside your app, you can use WKWebView
Also, not really what you asked for, but you should also look inside SFSafariViewController if you want some Safari related features such as Reader, AutoFill, Fraudulent Website Detection, and content blocking.
You can find more about SFSafariViewController
I want to go back and forward in my iOS apps WebView using "Screen Edge Pan Gesture Recognizer" like in Apples mobile Safari browser. Best would be if animated like in Safari.
Currently I use "Swipe Gesture Recognizer" but it isn't very easy to use for the users. Especially it doesn't work if user has zoomed the webpage.
Does anybody have a sample code, a manual or any other help?
This functionality is much easier to implement in WKWebView. You should simply set allowsBackForwardNavigationGestures property to YES.
WKWebView is a modern replacement for UIWebView, made by Apple. See link for details. You should link with WebKit.framework to use it. Unfortunately there is no Interface Builder support, see this answer.
Note that WKWebView available starting from iOS 8. Most likely you will receive crash on application start on earlier iOS versions. But it's possible to use UIWebView on pre-iOS 8, and WKWebView for iOS 8 and later. Take a look on this github project as an example.
I'm creating an ios/android app that is implemented with partially native code and html5/css and built-in mobile webkit, I need to make it support both ios and Android, hence the html5/css selection. In my app I created a tabbar with 4 tab buttons, each tabview contains a webview, the tabs and tabbars are implemented natively, meaning the code for this is either objective-c or Java. What happens in those webviews are html5/css/js... I wonder if this is the appropriate way to implement it, or should I wrap the whole thing up in one single webview, and implement everything using html5, including the tabbar. Or let me ask this way, what did facebook do with its tabbars in its app? I'm concerning about user experience and seamless transition/animation.
If I can mimic the native ios/Android tabbar using html5, how may I? Anyone could maybe provide a link to a tutorial? Thanks!
I'm moderately experienced with iOS, but I'm using UIWebView for the first time on this project.
I'm wondering, is there a way to monitor the line-by-line, internal operations of a UIWebView in Xcode? Maybe drop some NSLogs in there, or some breakpoints? The delegate methods cover the pre- and post-load stuff, but there doesn't seem to be any interface to actually track what the WebView itself does when it loads a page.
Specifically, I'd like to be able to track the app's behavior as each image from a webpage is downloaded and stored. I'm getting some weird errors around an image being unusable on iOS 7, but my PHP/JavaScript swears that everything is fine on its end, and the image seems fine on desktops and on iOS 6. I'm increasingly certain that the problem has to do with the WebView itself, (an answer to a related question seems to suggest it could be about WebKit calls on different threads), and I'd love to breakpoint my way through, or NSLog some key points or something, just to rule some stuff out.
Is anything like this possible? Or is UIWebView a private party that you can only hear about once it's over?
Does it break in Mobile Safari or only in your app?
You can point Safari's web inspector on OS X at Mobile Safari running in the iOS simulator or even on an iOS device (it has to be enabled in settings).
This will allow you to view all the HTTP headers and so on.
Another option is to use something like wireshark to monitor TCP traffic, but that's a lot more complicated.
http://webdesign.tutsplus.com/tutorials/workflow-tutorials/quick-tip-using-web-inspector-to-debug-mobile-safari/