https://github.com/xiaxiangfeng/e2number-string
科学计数法转数字字符串
https://github.com/xiaxiangfeng/e2number-string
Last synced: 2 months ago
JSON representation
科学计数法转数字字符串
- Host: GitHub
- URL: https://github.com/xiaxiangfeng/e2number-string
- Owner: xiaxiangfeng
- Created: 2017-12-05T13:50:41.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-02-07T03:40:36.000Z (over 7 years ago)
- Last Synced: 2025-02-12T11:37:50.201Z (4 months ago)
- Language: JavaScript
- Size: 70.3 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 科学计数法转数字字符串
> 注意:超大数会有精度问题;
例如 1333333333333333333333的科学计数法是1.3333333333333332e+21,
转字符串是133333333333333320000## 从NPM下载包
``` npm
npm i e2number-string
```## 使用实例
### 引入一个对象
``` js
import E2num from 'e2number-string'const e2Num = new E2num(val)
alert(e2Num.e2n())
```## 构建
``` bash
# 安装依赖
npm install# 打包
npm run build# 单元测试
npm unit
```