canLaunch function

Future<bool> canLaunch (String urlString)

Checks whether the specified URL can be handled by some app installed on the device.

Implementation

Future<bool> canLaunch(String urlString) async {
  if (urlString == null) {
    return false;
  }
  return await UrlLauncherPlatform.instance.canLaunch(urlString);
}