W3cubDocs

/JavaScript

Intl.NumberFormat.prototype

The Intl.NumberFormat.prototype property represents the prototype object for the Intl.NumberFormat constructor.

Property attributes of Intl.NumberFormat.prototype
Writable no
Enumerable no
Configurable no

Description

See NumberFormat for a description of Intl.NumberFormat instances.

Intl.NumberFormat instances inherit from Intl.NumberFormat.prototype. Modifications to the prototype object are inherited by all Intl.NumberFormat instances.

Properties

Intl.NumberFormat.prototype.constructor
A reference to Intl.NumberFormat.
Intl.NumberFormat.prototype.format
Getter; returns a function that formats a number according to the locale and formatting options of this NumberFormat object.

Methods

Intl.NumberFormat.prototype.formatToParts()
Returns an Array of objects representing the number string in parts that can be used for custom locale-aware formatting.
Intl.NumberFormat.prototype.resolvedOptions()
Returns a new object with properties reflecting the locale and collation options computed during initialization of the object.

Specifications

Browser compatibilityUpdate compatibility data on GitHub

Desktop
Chrome Edge Firefox Internet Explorer Opera Safari
Basic support 24 Yes 29 11 15 10
Mobile
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support No 26 Yes 56 ? 10 Yes
Server
Node.js
Basic support ?

See also

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/NumberFormat/prototype