Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/laem/frmttr
Simple and dirty number formatter based on d3.format
https://github.com/laem/frmttr
Last synced: 18 days ago
JSON representation
Simple and dirty number formatter based on d3.format
- Host: GitHub
- URL: https://github.com/laem/frmttr
- Owner: laem
- License: mit
- Created: 2014-11-10T11:12:16.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2014-11-10T15:12:23.000Z (about 10 years ago)
- Last Synced: 2023-03-22T20:11:04.447Z (over 1 year ago)
- Language: JavaScript
- Size: 2.55 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
frmttr
======Simple and dirty number formatter based on d3.format
Mainly useful to get two alternative notations from a number, e.g. for a bar chart.
```
1234567 -> { short: "1.2k", // the bar display value
alt: "1,234,567" // the alternative value that pops on hover
}
```Using https://github.com/mbostock/d3/wiki/Formatting