1 | # is-fullwidth-code-point
|
2 |
|
3 | > Check if the character represented by a given [Unicode code point](https://en.wikipedia.org/wiki/Code_point) is [fullwidth](https://en.wikipedia.org/wiki/Halfwidth_and_fullwidth_forms)
|
4 |
|
5 | ## Install
|
6 |
|
7 | ```
|
8 | $ npm install is-fullwidth-code-point
|
9 | ```
|
10 |
|
11 | ## Usage
|
12 |
|
13 | ```js
|
14 | import isFullwidthCodePoint from 'is-fullwidth-code-point';
|
15 |
|
16 | isFullwidthCodePoint('谢'.codePointAt(0));
|
17 | //=> true
|
18 |
|
19 | isFullwidthCodePoint('a'.codePointAt(0));
|
20 | //=> false
|
21 | ```
|
22 |
|
23 | ## API
|
24 |
|
25 | ### isFullwidthCodePoint(codePoint)
|
26 |
|
27 | #### codePoint
|
28 |
|
29 | Type: `number`
|
30 |
|
31 | The [code point](https://en.wikipedia.org/wiki/Code_point) of a character.
|
32 |
|
33 | ---
|
34 |
|
35 | <div align="center">
|
36 | <b>
|
37 | <a href="https://tidelift.com/subscription/pkg/npm-is-fullwidth-code-point?utm_source=npm-is-fullwidth-code-point&utm_medium=referral&utm_campaign=readme">Get professional support for this package with a Tidelift subscription</a>
|
38 | </b>
|
39 | <br>
|
40 | <sub>
|
41 | Tidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.
|
42 | </sub>
|
43 | </div>
|