Skip to main content

is_uri

Function is_uri 

Source
pub fn is_uri(target: &str) -> bool
Expand description

Check whether a target string is a URI.

Uses the url crate (WHATWG URL Standard) for parsing, then filters to URIs that either have authority (://) or use a known opaque scheme. Without this filter, any word:stuff parses as a URL — e.g. a YAML value like name: foo would be treated as a URI with scheme name.