code: function hasClass(element, name) {
      var list = typeof element == 'string' ? element : classList(element);
      return list.indexOf(' ' + name + ' ') >= 0;
    }
docs: (Internal) Determines if an element or space separated list of class names contains a class name.