Skip to content

Commit

Permalink
Add more explanations to readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Vitaly Puzrin committed Mar 5, 2017
1 parent 0bc3804 commit 59c5f0e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,15 @@
[![NPM version](https://img.shields.io/npm/v/unhomoglyph.svg?style=flat)](https://www.npmjs.org/package/unhomoglyph)

> Replace all homoglyphs with base characters. Useful to detect similar strings.
For example, to prohibit register similar looking nicknames at websites.

Data source - [Recommended confusable mapping for IDN](http://www.unicode.org/Public/security/latest/confusables.txt), v9.0.0.

__Note!__ Text after transform is NOT intended be read by humans. For example,
`m` will be transformed to `r` + `n`. Goal is to compare 2 strings after
transform, to check if sources looks similar or not. If sources look similar,
then transformed strings are equal.


## Install

Expand All @@ -21,6 +27,7 @@ npm install unhomoglyph --save
const unhomoglyph = require('unhomoglyph');

console.log(unhomoglyph('AΑАᎪᗅᴀꓮ')); // => AAAAAAA
console.log(unhomoglyph('m')); // => rn (r + n)
```


Expand Down

0 comments on commit 59c5f0e

Please sign in to comment.