Module: util/bignum
References
default
Re-exports default
Type Aliases
DecimalSource
Ƭ DecimalSource: DecimalSource
Defined in
profectus/src/util/bignum.ts:18
Functions
commaFormat
▸ commaFormat(num
, precision
): string
Parameters
Name | Type |
---|---|
num | DecimalSource |
precision | number |
Returns
string
exponentialFormat
▸ exponentialFormat(num
, precision
, mantissa?
): string
Parameters
Name | Type | Default value |
---|---|---|
num | DecimalSource | undefined |
precision | number | undefined |
mantissa | boolean | true |
Returns
string
format
▸ format(num
, precision?
, small?
): string
Parameters
Name | Type |
---|---|
num | DecimalSource |
precision? | number |
small? | boolean |
Returns
string
formatSmall
▸ formatSmall(x
, precision?
): string
Parameters
Name | Type |
---|---|
x | DecimalSource |
precision? | number |
Returns
string
formatTime
▸ formatTime(seconds
): string
Parameters
Name | Type |
---|---|
seconds | DecimalSource |
Returns
string
formatWhole
▸ formatWhole(num
): string
Parameters
Name | Type |
---|---|
num | DecimalSource |
Returns
string
invertOOM
▸ invertOOM(x
): default
Parameters
Name | Type |
---|---|
x | DecimalSource |
Returns
regularFormat
▸ regularFormat(num
, precision
): string
Parameters
Name | Type |
---|---|
num | DecimalSource |
precision | number |
Returns
string
toPlaces
▸ toPlaces(x
, precision
, maxAccepted
): string
Parameters
Name | Type |
---|---|
x | DecimalSource |
precision | number |
maxAccepted | DecimalSource |
Returns
string