Creating a Wrapper for Firebug's Console [Tips & Tricks] | Posted at 12:20 PM
Thanks to Dimitar over at Frag on how to create a wrapper for Firebug's console, I was able to implement better debugging in my jQuery plugin. The one quip I had was that I needed to directly pass everything to the log function. The way Dimitar did it, it wrote a log line for each argument. I was passing formatted strings.
Here are the offending lines:
for (var i = 0, l = arguments.length; i < l; i++) console.log(arguments[i]);
And here's what you replace it with:
BAM! Works like a charm.