-
Notifications
You must be signed in to change notification settings - Fork 9.7k
[webview_flutter]Adding error message display on iOS WebView #979
Conversation
|
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here (e.g. What to do if you already signed the CLAIndividual signers
Corporate signers
|
|
I signed it! |
|
CLAs look good, thanks! |
|
Could this also happen on Android? |
|
@ened |
|
@hatzyuta Perhaps yes, especially as the INTERNET permission on Android is not per se a requirement for WebView. (It could be used to display a bundled HTML file, too). I think it would be good to have complete error logs on all platforms. |
|
@ened |
|
@ened |
amirh
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the contribution! left a comment, this will also need to be rebased.
| - (void)webView:(WKWebView*)webView | ||
| didFailNavigation:(WKNavigation*)navigation | ||
| withError:(NSError*)error { | ||
| NSLog(@"%@", error.description); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd suggest that we allow the Flutter application to register error listeners and invoke these, giving the app developer the power to decide whether to print error messages or to do something else with them.
|
It actually seems that what I've suggested is addressed by #1788 given that the other PR is closer to be merge-able I'd suggest closing the current PR. |
|
Closing this PR as the issue is addressed by #1788 |
On iOS, when WebView failed to load web pages for some reasons(e.g. 'ATS' on iOS),there is no process to show error messages to developers in the current version of 'webview_flutter' plugin.
I added error message display especially on iOS so that developers realize the reason why webview fails to load.