English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
valueOf()The method returns the original value of the specified object. This is the default method of the array object, which belongs to the Object object. Since all objects 'inherit' the object instance of Object, almost all instance objects can use this method.
Note:valueOf()The method does not change the original array.
array.valueOf()
var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May']; months.valueOf();Test and see‹/›
All browsers fully support the valueOf() method:
Method | |||||
valueOf() | Yes | Yes | Yes | Yes | Yes |
Return value: | Specify the original value of the array |
---|---|
JavaScript Version: | ECMAScript 1 |