hash-ids

Crates.iohash-ids
lib.rshash-ids
version0.2.1
sourcesrc
created_at2020-05-12 21:22:23.915259
updated_at2020-05-14 20:51:20.874117
descriptiona fast hashids (hashids.org) implementation
homepage
repositoryhttps://github.com/kardeiz/hash-ids
max_upload_size
id240832
size20,098
Jacob Brown (kardeiz)

documentation

https://docs.rs/hash-ids

README

hash-ids

A fast, dependency-free implementation for hashids.

Usage

fn main() {
    let hash_ids = hash_ids::HashIds::builder()
        .with_salt("Arbitrary string")
        .finish(); 
    assert_eq!("neHrCa", hash_ids.encode(&[1, 2, 3]));
    assert_eq!(vec![1, 2, 3], hash_ids.decode("neHrCa"));
}
Commit count: 5

cargo fmt