How do I console.log a jQuery DOM Element in Chrome?

Update: I made a jQuery plugin to bring back the old style logging: jquery.chromelog.


You could create a little function to log all elements on one line:

$.fn.log = function() {
  console.log.apply(console, this);
  return this;
};

Usage:

$("...").log();

Leave a Comment