0.1.1 • Published 3 years ago
quiktime v0.1.1
⏱ quiktime
Quickly format duration time values in a condensed format.
Install
Via npm
npm install quiktimeVia Yarn
yarn add quiktimeHow to use
Without Options
import quiktime from 'quiktime'
console.debug(quiktime(1200))
===
Output: 1.2 msWith Options
import quiktime from 'quiktime`
console.debug(quiktime(1234, { maximumFractionDigits: 3 }))
===
Output: 1.234 msOptions
minimumIntegerDigits: number- The minimum number of integer digits to use. Possible values are from1to21; the default is1.minimumFractionDigits: number- The minimum number of fraction digits to use. Possible values are from0to20; the default is0.maximumFractionDigits: number- The maximum number of fraction digits to use. Possible values are from0to20; the default is2