jquery/jquery — pull request #1197 by bretterer (2013-03-06 22:36:49+00:00)
Title: Added .hasAnyClass() method

This method will allow developers to reduce the amount of code when check if an element has a bunch of classes

**OLD**

if(el.hasClass('one') || el.hasClass('two') || el.hasClass('three')) {
// Do Somethind
}

**WITH .hasAnyClass()**

if(el.hasAnyClass(['one','two','three']) {
// Do Something
}

**DOCUMENTATION**

.hasAnyClass( classes, returnClasses )
classes
Type: Array
The array of classes you want to test.

returnClasses
Type: boolean
Default: false
Set to true if you want to get a list of the classes that match