jQuery's variable $ for example works both as object and function.
// You can access object properties such as
$.fn;
// or
$.isReady;
// You can also call the function $ such as follows
$();
How to make variable $ works both as object and function?
$ = function(){} // ???
$ = {}; // ???