1.0.6 • Published 5 years ago

format-unit v1.0.6

Weekly downloads
3
License
UNLICENSED
Repository
github
Last release
5 years ago

format-unit

Format length or area units to human readable Strings.

Usage

// install
import formatUnit from 'format-unit'

// meters to ha
formatUnit('area')(200000)('ha')

// ha to meters
formatUnit('area')(200000)('m')

// meters to "prettiest" unit
formatUnit('area')(200000)(['m2', 'a', 'ha', 'km2'])

// m to km
formatUnit('length')(2000)('km')

Lincese

UNLICENSED

1.0.6

5 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago