I noticed this the other day for the first time while checking out the "CamanJS" project. This question is difficult to explain unless you just do it. If you go to camanjs.com, then using either Firebug or the Chrome JavaScript console, type in the word Caman and press enter. Not Caman() with parentheses -- just Caman. It will output: Version 4.1.0, Released 2/12/2013.
But if you look at typeof Caman, it's just a "function." So how on earth do you get it to output a custom string like that, without actually calling the function? Is that done through some sort of prototype extension?
valueOf:var x = function () {}; x.valueOf = function () {return 5;}; // x + 3 === 8