Repository Details
Shared by
HelloGitHub Rating
0 ratings
阿拉伯数字与中文数字相互转化的 JS 库
Past 7 days Received -1 stars ✨
Use arrow keys to explore dates, Home and End for the first and last date, Escape to dismiss.| Date | Star | Daily change |
|---|---|---|
| 周二 | 1,517 | — |
| 周三 | 1,517 | 0 |
| 周四 | 1,517 | 0 |
| 周五 | 1,517 | 0 |
| 周六 | 1,516 | -1 |
| 周日 | 1,516 | 0 |
| 周一 | 1,516 | 0 |
1.5k
Stars
Yes
Chinese
JavaScript
Language
No
Active
10
Contributors
6
Issues
No
Organization
None
Latest
136
Forks
None
License
阿拉伯数字与中文数字相互转化的 JS 库。示例代码如下:
```javascript
var nzhcn = Nzh.cn; // 使用简体中文, 另外有 Nzh.hk -- 繁体中文
nzhcn.encodeS(100111); // 转中文小写 >> 十万零一百一十一
nzhcn.encodeB(100111); // 转中文大写 >> 壹拾万零壹佰壹拾壹
nzhcn.encodeS("1.23456789e+21"); // 科学记数法字符串 >> 十二万三千四百五十六万万七千八百九十万亿
nzhcn.toMoney("100111.11"); // 转中文金额 >> 人民币壹拾万零壹佰壹拾壹元壹角壹分
```
Included in:
Vol.43
Comments
Rating:
No comments yet