#parse-url #lib #parser

miniurl

miniurl is a url parser lib for rust

4 releases

Uses old Rust 2015

0.1.3 Aug 17, 2017
0.1.2 Aug 13, 2017
0.1.1 Aug 13, 2017
0.1.0 Aug 12, 2017

#48 in #parse-url

Download history 17/week @ 2024-03-30 5/week @ 2024-04-06 4/week @ 2024-04-13 5/week @ 2024-04-20 1/week @ 2024-04-27 6/week @ 2024-05-11 9/week @ 2024-05-18 3/week @ 2024-05-25 6/week @ 2024-06-01 3/week @ 2024-06-08 19/week @ 2024-06-15 179/week @ 2024-06-22 4/week @ 2024-06-29 2/week @ 2024-07-13

188 downloads per month
Used in 2 crates

MIT/Apache

10KB
172 lines

miniurl is url parser lib for rust,is simple and easy.

Examples

use miniurl::Url;

let url = Url::parse("http://admin:password@google.com/foo?a=1&b=2#top");
assert_eq!(url.scheme, "http");
assert_eq!(url.netloc, "admin:password@google.com");
assert_eq!(url.path, "/foo");
assert_eq!(url.query, Some("a=1&b=2".to_string()));
assert_eq!(url.fragment, Some("top".to_string()));
assert_eq!(url.username, Some("admin".to_string()));
assert_eq!(url.password, Some("password".to_string()));
assert_eq!(url.host, Some("google.com".to_string()));
assert_eq!(url.port, 80);

No runtime deps