10 releases
0.3.5 | Mar 15, 2020 |
---|---|
0.3.4 | Feb 2, 2020 |
0.3.1 | Jan 5, 2020 |
0.2.2 | Dec 29, 2019 |
0.1.0 | Nov 30, 2019 |
#49 in #query-string
128 downloads per month
Used in 3 crates
20KB
393 lines
urlqstring
Introduce
urlqstring is a general library for url query string
This crate is a general purpose library for common function found when working with the request's query parameters. This library aims to implement the querystring function in Nodejs
Install Tutoria
Add the urlqstring crate dependency in your project's toml file, such as:
[dependencies]
urlqstring = "0.3.4"
Instructions
Please refer to the documentation for detauled instructions: urlqstring doc
lib.rs
:
A general library for url query string
This crate is a general purpose library for common function found when working with the request's query parameters.
This library aims to implement the querystring function in Nodejs
Supported Types
For the library user, urlqstring will supports struct, map, and the string of query parameters style
Usage
See the examples as below.
use urlqstring::QueryParams;
fn main() {
let enc1 = QueryParams::from(vec![
("params", "度"),
("enc", "=-)(&#+~·@…%^$:*-_."),
]).stringify();
let res1: String= String::from("params=%E5%BA%A6&enc=%3D-)(%26%23%2B~%C2%B7%40%E2%80%A6%25%5E%24%3A*-_.&");
assert_eq!(enc1, res1);
}