tothousand

0.1.0 • Public • Published

tothousand

介绍

将项目中的金额处理成千分位

软件架构

javascript

安装教程

npm install tothousand --save

使用说明

  1. import tothousand from 'tothousand'
  2. 接收参数: num:要转化为千分位的金额 isnone:如果是空数字,输出内容,默认:'-' any:保留几位小数,支持保留 0、1、2 位小数,默认:2 unit 单位:万元、元,默认没有单位
  3. 使用方法: let targetMoney = tothousand(num, isnone, any, unit)
  4. example: let targetMoney = tothousand(200000, "--", "2", "元") // 200,000.00元

参与贡献

liuming(https://ioolm.com)

支持

  1. 使用 Readme_XXX.md 来支持不同的语言,例如 Readme_en.md, Readme_zh.md
  2. Gitee 官方博客 blog.gitee.com
  3. 你可以 https://gitee.com/explore 这个地址来了解 Gitee 上的优秀开源项目
  4. GVP 全称是 Gitee 最有价值开源项目,是综合评定出的优秀开源项目
  5. Gitee 官方提供的使用手册 https://gitee.com/help
  6. Gitee 封面人物是一档用来展示 Gitee 会员风采的栏目 https://gitee.com/gitee-stars/

Dependents (0)

Package Sidebar

Install

npm i tothousand

Weekly Downloads

0

Version

0.1.0

License

ISC

Unpacked Size

15.4 kB

Total Files

5

Last publish

Collaborators

  • ioolm