Namespace: number

Functions

toFixed

toFixed(num, fixed): string

Returns the specified number with a fixed specified amount of decimals without doing any rounding as a string.

Example: toFixed(1.126, 2) => 1.12 while the standard function would: 1.126.toFixed(2) => 1.13.

Parameters

Name Type
num number
fixed number

Returns

string