isURL static method
Returns true for a valid URL.
Implementation
static bool isURL(String value) {
final Uri? uri = Uri.tryParse(value.trim());
if (uri == null) return false;
return (uri.scheme == 'http' || uri.scheme == 'https') &&
uri.host.isNotEmpty;
}