Skip to content

Commit f8a1344

Browse files
author
bors-servo
committed
Auto merge of #131 - conradkleinespel:patch-2, r=SimonSapin
Adds docs about query string decoding Hello, I was [looking](https://twitter.com/kleinespel/status/643462183783923712) for a library to decode a query string from a URL, when I hadn't realised `url::form_urlencoded::parse` did just that. I hope this little doc addition makes things a bit more clear. Best regards, Conrad <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/rust-url/131) <!-- Reviewable:end -->
2 parents 6f90be3 + ff02193 commit f8a1344

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -393,6 +393,9 @@ impl<'a> UrlParser<'a> {
393393
/// assert_eq!(query, Some("q=42".to_string()));
394394
/// assert_eq!(fragment, None);
395395
/// ```
396+
///
397+
/// The query string returned by `url::parse_path` can be decoded with
398+
/// `url::form_urlencoded::parse`.
396399
#[inline]
397400
pub fn parse_path(input: &str)
398401
-> ParseResult<(Vec<String>, Option<String>, Option<String>)> {

0 commit comments

Comments
 (0)