Created
January 9, 2019 02:01
-
-
Save lawreyios/8cd23e2af0d5bed1a5ae8b8086f56a5c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import 'package:url_launcher/url_launcher.dart'; | |
| class URLLauncher { | |
| launchURL(String url) async { | |
| if (await canLaunch(url)) { | |
| await launch(url); | |
| } else { | |
| throw 'Could not launch $url'; | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment