isUrl property

bool get isUrl

Returns true if the string is a valid URL.

Implementation

bool get isUrl => Uri.tryParse(this)?.hasAbsolutePath ?? false;