The toLocaleString() Method

In ECMAScript v3 and JavaScript 1.5, the Object class defines a toLocaleString() method in addition to
its toString() method. The purpose of this method is to return a localized string representation of the
object. The default toLocaleString() method defined by Object doesn't do any localization itself; it always
returns exactly the same thing as toString() . Subclasses, however, may define their own versions of
toLocaleString() . In ECMAScript v3, the Array, Date, and Number classes do define toLocaleString()
methods that return localized values.

你可能感兴趣的:(JavaScript)