title: Custom console log function, a console.log wrapper
body: <pre><code>function log( msgOrObj ){
      if(dev_mode){
          console.log({
              'message': msgOrObj,
              'caller': arguments.callee.caller.toString()
          });
      }
  }
  </code></pre>
  
  <p>So, I have attempted to write a simple custom console log function (as above). However I am struggling to find which file and line the caller came from. The most I can see is the function that called it. </p>
  
  <p>Has anyone done anything similar? Or is this even possible?</p>
  
  <p>example used in somescript.js from line 70:</p>
  
  <pre><code>log('some very important message!')
  </code></pre>