The Function constructor creates a new Function object. In JavaScript
every function is actually a Function object.
Functions are glorified objects.
https://developer.mozilla.org/de/docs/Web/JavaScript/Reference/Global_Objects/Function
Of course, but the real question is why String Inherits from Function
and JSON Inherits from Object. I can see no sense in this. For example
if you add a method to the Function prototype, it will be available to
String but not to JSON
A JavaScript object is a mapping between keys and values. Keys are strings and values can be anything. This makes objects a natural fit for hashmaps.
Functions are regular objects with the additional capability of being callable.
You can instantiate a String but you cannot instantiate a Math object. This is maybe the fact confusing you.
alert(new String());
alert(new Math());