JavaScript: The Definitive Guide

24.136. Number.toLocaleString( ): convert a number to a locally formatted string

ECMAScript v3

24.136.1. Synopsis

number.toLocaleString( )

24.136.1.1. Returns

An implementation-dependent string representation of the number, formatted according to local conventions, which may affect such things as the punctuation characters used for the decimal point and the thousands separator.

24.136.1.2. Throws

TypeError

If this method is invoked on an object that is not a Number.

24.136.2. See Also

Number.toExponential( ), Number.toFixed( ), Number.toPrecision( ), Number.toString( )

Категории