Function.valueOf() (Method)

Returns a string primitive version of the function.


ECMAScript edition - 2
JavaScript - 1.1
Netscape - 4.0
Property/method value type:String primitive
JavaScript syntax:NmyFunction.valueOf()

This value is identical to the toString() method (exclusive to Netscape). The recommended approach is to use toString() instead of valueOf() for reasons of consistency.

The result of calling this method is to obtain the source text of the function definition unless it is a host implemented function.

See also:Function.toString()


ECMA 262 edition 2 - section - 15.3.4