Skip to content
On this page

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

NameType
numDecimalSource
precisionnumber

Returns

string


exponentialFormat

exponentialFormat(num, precision, mantissa?): string

Parameters

NameTypeDefault value
numDecimalSourceundefined
precisionnumberundefined
mantissabooleantrue

Returns

string


format

format(num, precision?, small?): string

Parameters

NameType
numDecimalSource
precision?number
small?boolean

Returns

string


formatSmall

formatSmall(x, precision?): string

Parameters

NameType
xDecimalSource
precision?number

Returns

string


formatTime

formatTime(seconds): string

Parameters

NameType
secondsDecimalSource

Returns

string


formatWhole

formatWhole(num): string

Parameters

NameType
numDecimalSource

Returns

string


invertOOM

invertOOM(x): default

Parameters

NameType
xDecimalSource

Returns

default


regularFormat

regularFormat(num, precision): string

Parameters

NameType
numDecimalSource
precisionnumber

Returns

string


toPlaces

toPlaces(x, precision, maxAccepted): string

Parameters

NameType
xDecimalSource
precisionnumber
maxAcceptedDecimalSource

Returns

string