#url #querystring #percent-code

urlqstring

A URL query string for rust

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

#8 in #querystring

Download history 32/week @ 2021-10-01 24/week @ 2021-10-08 10/week @ 2021-10-15 9/week @ 2021-10-22 14/week @ 2021-10-29 26/week @ 2021-11-05 6/week @ 2021-11-12 20/week @ 2021-11-19 12/week @ 2021-11-26 26/week @ 2021-12-03 14/week @ 2021-12-10 12/week @ 2021-12-17 20/week @ 2021-12-24 30/week @ 2021-12-31 18/week @ 2022-01-07 20/week @ 2022-01-14

89 downloads per month
Used in 2 crates

Custom license

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);
}

No runtime deps

Nn^