jQuery Misc

Miscellaneous methods.

jQuery Misc Methods

jQuery has a lot of miscellaneous methods that do not fit into the other categories.

Some important ones:

  • data() - Attaches data to an element
  • each() - Iterates over elements
  • index() - Returns the index of an element
  • $.noConflict() - Releases the $ variable

Example

$("li").each(function(index){
  console.log(index + ": " + $(this).text());
});