Thank you for your suggestions. The new wkwebview works well. However in my case, I have to remove ios platform as well as the cordova webserver plugin folder before add the platform back for it to install and run properly.
I can also confirm that removing “file://” prefix work!
One issue I get with WKWebView (which doesn’t happen with UIWebView) is that a scrollbar appears randomly (I think) on pages with scroll-content. This happens like 50% or so of the time, so sometimes the scrollbar appears and sometimes not.
However, if I connect the device to a computer and use the Safari inspector and remove “-webkit-overflow-scrolling: touch;” from class “scroll-content”, the scrollbar goes away. Of course the scrolling experience is horrible then though.
Anyone have the same issue and know what causes it or what could be done to fix it?
Hi,
I have added the plugin using below command in the command line.
ionic plugin install https://github.com/driftyco/cordova-plugin-wkwebview-engine --save
After adding this plugin, When I try to build using XCode its throwing lot of errors like
-> CDVWebViewDelegate.h is missing.
-> Register plugin is in not available in CDVViewController.
-> InitwithView:settings: is not available in CDVLocalStorage class.
etc etc…
Most everything seems to be going smoothly for me except that I can’t seem to use canvas.toDataURL, which I need for some dynamic image creation. Is this not supported yet? Thanks!
@mhartington I’m a little confused about the status of this plugin? Can we use it in production? And I’ve seen some announcements that WKWebview will be the default in Ionic shortly (tweet from Max on April 3). Can you clarify if and how we can use WKWebview in our Ionic 3 apps.
I’ve been successful using WKWebview in ionic 3.2.1 following the instructions in the git readme. My app uses firebase/angularfire/ionic deploy/stripe/onesignal and everything seems to be working fine!
@maith123 Thanks for the input. I’m using firebase/angularfire/ionic as well. It seems to be working, but I’m still not sure whether I should use it in a production app. I’m wondering why it hasn’t been added to ionic2-app-base yet.
I’m getting an error trying to install this.
Any suggestions would be appreciated.
This is my system info and the error header:
global packages:
@ionic/cli-utils : 1.2.0
Cordova CLI : 7.0.1
Ionic CLI : 3.2.0
local packages:
@ionic/app-scripts : 1.3.7
@ionic/cli-plugin-cordova : 1.2.1
@ionic/cli-plugin-ionic-angular : 1.2.0
Cordova Platforms : android 6.2.3 ios 4.4.0
Ionic Framework : ionic-angular 3.1.1
System:
Node : v6.9.4
OS : macOS Sierra
Xcode : not installed
ios-deploy : 1.9.0
ios-sim : not installed
[ERROR] Cordova encountered an error.
You may get more insight by running the Cordova command above directly.
[ERROR] An error occurred while running cordova plugin add https://github.com/driftyco/cordova-plugin-wkwebview-engine.g... (exit code 1):
Error: Failed to fetch plugin https://github.com/driftyco/cordova-plugin-wkwebview-engine.git via registry.
Probably this is either a connection problem, or plugin spec is incorrect.
Check your connection and plugin name/version/URL.
Did you try to install https://github.com/driftyco/cordova-plugin-wkwebview-engine.git with .git at the end?
Maybe that’s the cause. Remove .git at the end and try it once more:
actually, there is some problem. when using wkwebview the media plugin do not create media object in background-mode. either used with cordova background-mode plugin or not still wont work.
I’m not sure if this is media plugin issue or the wkwebview issue.
Hi,
When I update to latest version I am getting following error on Simulator.
{"code":"ResourceNotFound","message":"/Users/shashwat/Library/Developer/CoreSimulator/Devices/B0643839-BA5C-4CD4-A6C7-B404AACF5E5F/data/Containers/Bundle/Application/37DC9839-F513-4840-B153-8504EE1DADCA/WeatherSpork.app/www/index.html does not exist"}
It doesn’t work for me neither in simulator or real device.
See timeout error in xcode when trying to load the index.html and the hangs on splash screen. Also tried with new empty app based on tabs template. Same effect… Any ideas?