How can I access a function name from inside that function?
// parasitic inheritance var ns.parent.child = function() { var parent = new ns.parent(); p
You could use this, for browsers that support Error.stack (not nearly all, probably)
function WriteSomeShitOut(){ var a = new Error().stack.match(/at (.*?) /); console.log(a[1]); } WriteSomeShitOut();
of course this is for the current function, but you get the idea.
happy drooling while you code