In JavaScript, the constructor property returns the constructor function for an object.
In JavaScript, the constructor property returns the constructor function for an object.
The return value is a reference to the function, not the name of the function:
For JavaScript numbers the constructor property returns function Number() { [native code] }
number.constructor
function Number() { [native code] }
The constructor property returns a number's constructor function:
var num = 1.5;
console.log(num.constructor);