2 releases

0.1.1 Jul 4, 2024
0.1.0 Feb 15, 2023

#844 in Text processing

Download history 2566/week @ 2024-12-21 2265/week @ 2024-12-28 3119/week @ 2025-01-04 3152/week @ 2025-01-11 2662/week @ 2025-01-18 2611/week @ 2025-01-25 2626/week @ 2025-02-01 2829/week @ 2025-02-08 2826/week @ 2025-02-15 2739/week @ 2025-02-22 3054/week @ 2025-03-01 3441/week @ 2025-03-08 3453/week @ 2025-03-15 3152/week @ 2025-03-22 5846/week @ 2025-03-29 3526/week @ 2025-04-05

16,483 downloads per month
Used in 10 crates (via charabia)

MIT license

130KB
160 lines

kvariants

A Rust crate wrapping https://github.com/hfhchan/irg/blob/master/kVariants.md made by @hfhchan. If you want to participate in improving this dictionary, don't hesitate to create an issue or submit a PR directly on the dictionary repository.

Usage

use kvariants::KVARIANTS;

let c = '';

let kvariant = match KVARIANTS.get(&c) {
    Some(kvariant) => kvariant.destination_ideograph,
    None => c,
};

assert_eq!(kvariant, '');

Fetch latest dictionary from upstream

The dictionary file is vendored into dictionaries/source/ and can be updated with bin/sync_dictionaries.

Dependencies

~1.4–2.2MB
~33K SLoC