#unicode #confusable #homoglyphs

confusables

Utilities around Unicode confusables/homoglyphs

1 unstable release

0.1.0 Aug 23, 2023

#1086 in Text processing

Download history 421/week @ 2024-04-12 1040/week @ 2024-04-19 248/week @ 2024-04-26 144/week @ 2024-05-03 225/week @ 2024-05-10 205/week @ 2024-05-17 97/week @ 2024-05-24 148/week @ 2024-05-31 218/week @ 2024-06-07 263/week @ 2024-06-14 253/week @ 2024-06-21 226/week @ 2024-06-28 236/week @ 2024-07-05 262/week @ 2024-07-12 245/week @ 2024-07-19 312/week @ 2024-07-26

1,063 downloads per month

GPL-3.0 license

130KB
120 lines

Confusables

Build & Tests Crates.io docs.rs

A Rust crate that provides utilities around Unicode confusables/homoglyphs. Specifically about:

  • detecting confusable characters in strings
  • replacing confusable characters (according to the data file specified in the Unicode® Technical Standard)
  • confusable-resilient operations (equality, contains) on strings

The Unicode data file is parsed at compile time so there is no extra overhead at runtime.

Get Started

All the new methods are implemented as part of a trait which you will need to import:

use confusables::Confusable;

All methods come with code examples so be sure to check those!

Dependencies