core/util.js
function indexOf(list, item) {
  if (NATIVE_ARRAY_INDEXOF) {
    return NATIVE_ARRAY_INDEXOF.call(list, item);
  }

  for (var i = 0; i < list.length; i++) {
    if (list[i] === item) {
      return i;
    }
  }

  return -1;
}
function indexOf(list, item) {
  if (NATIVE_ARRAY_INDEXOF) {
    return NATIVE_ARRAY_INDEXOF.call(list, item);
  }

  for (var i = 0; i < list.length; i++) {
    if (list[i] === item) {
      return i;
    }
  }

  return -1;
}
function indexOf ( list , item ) { if ( NATIVE_ARRAY_INDEXOF ) { return NATIVE_ARRAY_INDEXOF . call ( list , item ) ; } for ( var i = 0 ; i < list . length ; i ++ ) { if ( list [ i ] === item ) { return i ; } } return - 1 ; }
Backwards compatible Array.prototype.indexOf
@param {array} list List of items.
@param {object} item Item to search for.
@return {number} Index of match or -1 if not found.
Backwards compatible Array . prototype . indexOf