File tree Expand file tree Collapse file tree 1 file changed +38
-1
lines changed Expand file tree Collapse file tree 1 file changed +38
-1
lines changed Original file line number Diff line number Diff line change 1
1
# unicode-scripts-finder
2
2
3
- find which unicode scripts a text is using
3
+ Find which unicode scripts a text is using
4
+
5
+ Status: WIP but already somewhat useful
6
+
7
+ ## Install
8
+ To use the JS module in a project:
9
+ ``` sh
10
+ npm i unicode-scripts-finder
11
+ ```
12
+
13
+ To use the CLI, rather install it globally to make the command ` unicode-scripts-finder ` available in your $PATH:
14
+ ``` sh
15
+ npm i -g unicode-scripts-finder
16
+ ```
17
+
18
+ ## Module
19
+ ``` js
20
+ const unicodeScriptsFinder = require (' unicode-scripts-finder' )
21
+
22
+ unicodeScriptsFinder (' Lorem ipsum dolor sit amet' )
23
+
24
+ [ { label: ' Latin' , count: 370 }
25
+ ]
26
+
27
+ unicodeScriptsFinder (' ἀπόστασις' ).should .deepEqual ([
28
+ { label: ' Greek' , count: 9 }
29
+ ])
30
+
31
+ unicodeScriptsFinder (' Lorem ipsum ἀπόστασις' ).should .deepEqual ([
32
+ { label: ' Latin' , count: 10 },
33
+ { label: ' Greek' , count: 9 }
34
+ ])
35
+ ```
36
+
37
+ ## CLI
38
+ ``` sh
39
+ unicode-scripts-finder Lorem ipsum dolor sit amet
40
+ ```
You can’t perform that action at this time.
0 commit comments