My question is how to close the launcher view after creating it ?
urlLauncher(String url) async {
if (await canLaunch(url)) {
await launch(url, forceWebView: true);
} else {
throw 'Could not launch $url';
}
}
I found a solution for that This pull request adds the closeWebView method, so that the web view can be closed programmatically. To use the version of the pull request, use this in pubspec.yaml:
dependencies:
url_launcher:
git:
url: git://github.com/flutter/plugins.git
path: packages/url_launcher
ref: 2c56dd4cca2f5b85619eaea425baccb1e0600886
check your indentations in the yaml files as it is very important..
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