English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
MAX_VALUEThe property represents the maximum numerical value that can be represented in JavaScript.
The value of the MAX_VALUE property is approximately1.79E + 308or2 1024.
Values greater than MAX_VALUE are represented as “infinity”.
Since MAX_VALUE is a static property of Number, it is always used asNumber.MAX_VALUE, rather than using it as an attribute of the Number object you create.
Number.MAX_VALUE
Number.MAX_VALUE;Test and see‹/›
All browsers fully support the MAX_VALUE property:
Property | |||||
MAX_VALUE | Yes | Yes | Yes | Yes | Yes |
Writable: | None |
---|---|
Enumerable: | None |
Configurable: | None |
Return Value: | A number1.7976931348623157e + 308 |
JavaScript Version: | ECMAScript 1 |
Calling MAX_VALUE on the object you create (not the Number itself) will result in an undefined value:
var num = 20; num.MAX_VALUE;// undefinedTest and see‹/›