Created
September 8, 2010 23:37
-
-
Save markhepburn/571063 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery.fn.log = function (msg) { | |
console.log("%s: %o", msg, this); | |
return this; | |
}; | |
// $('selector').log('BEGIN') | |
// .css('color', 'red') | |
// .log('new value') | |
// // etc | |
// From http://msdn.microsoft.com/en-us/scriptjunkie/ee819093.aspx | |
// which credits http://happygiraffe.net/blog/2007/09/26/jquery-logging/ | |
// (which is unavailable right now) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment