9 releases

0.3.1 Apr 6, 2022
0.3.0 Sep 3, 2021
0.2.0 Apr 18, 2021
0.1.7 Oct 19, 2020
0.1.3 Feb 27, 2020

#136 in Text processing

Download history 2326/week @ 2022-10-07 2414/week @ 2022-10-14 2619/week @ 2022-10-21 3054/week @ 2022-10-28 2546/week @ 2022-11-04 2801/week @ 2022-11-11 4434/week @ 2022-11-18 4301/week @ 2022-11-25 2145/week @ 2022-12-02 3681/week @ 2022-12-09 3122/week @ 2022-12-16 2209/week @ 2022-12-23 5088/week @ 2022-12-30 4617/week @ 2023-01-06 5438/week @ 2023-01-13 5430/week @ 2023-01-20

21,242 downloads per month
Used in 59 crates (5 directly)

ISC license

240KB
749 lines

AnyAscii build

Unicode to ASCII transliteration

Web Demo

Converts Unicode characters to their best ASCII representation

AnyAscii provides ASCII-only replacement strings for practically all Unicode characters. Text is converted character-by-character without considering the context. The mappings for each script are based on popular existing romanization systems. Symbolic characters are converted based on their meaning or appearance. All ASCII characters in the input are left unchanged, every other character is replaced with printable ASCII characters. Unknown characters and some known characters are replaced with an empty string and removed.

use any_ascii::any_ascii;

let s = any_ascii("άνθρωποι");
// anthropoi

Rust 1.42+ compatible

# Cargo.toml
[dependencies]
any_ascii = "*"

Install executable: cargo install any_ascii

$ anyascii άνθρωποι
anthropoi

$ echo άνθρωποι | anyascii
anthropoi

FULL README

No runtime deps