You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I encountered this matter yesterday and it took me a day to fix it. At first, I think it relates to Info.plist configuration, something like App Transport Security, but it is not my case. In my case, my application works well as a Flutter standard alone application but when I add it to my existing application, my WebView keeps showing loading state forever.
Try to debug it in Xcode and here is what I've found: The plugin uses rootViewController as the current visible ViewController, it only works in case the application has only one ViewController, but in case of Add2App, the application has many ViewController, our FlutterViewController is one of them. By using the wrong ViewController, the following code doesn't work:
The result is that WKWebView has never been attached to the current ViewController (a FlutterViewController in this case) and the UI shows loading forever.
I encountered this matter yesterday and it took me a day to fix it. At first, I think it relates to
Info.plist
configuration, something like App Transport Security, but it is not my case. In my case, my application works well as a Flutter standard alone application but when I add it to my existing application, my WebView keeps showing loading state forever.Try to debug it in Xcode and here is what I've found: The plugin uses
rootViewController
as the current visibleViewController
, it only works in case the application has only oneViewController
, but in case of Add2App, the application has manyViewController
, ourFlutterViewController
is one of them. By using the wrongViewController
, the following code doesn't work:The result is that
WKWebView
has never been attached to the currentViewController
(aFlutterViewController
in this case) and the UI shows loading forever.Here's my solution to solve this matter:
Hope that it is useful.
The text was updated successfully, but these errors were encountered: