Rick Waldron (2014-03-05T16:11:21.000Z)
domenic at domenicdenicola.com (2014-03-20T16:08:19.547Z)
On Wed, Mar 5, 2014 at 7:04 AM, Sebastian Zartner <sebastianzartner at gmail.com> wrote: > While .indexOf() just gets you the index of one item, .contains() could > even be extended to allow to check whether an array contains several items. > E.g. > > ```js > .contains([1, 2, 3], [1, 3]) // true > .contains([1, 2, 3], [1, 4]) // false > ``` String.prototype.contains already has a second parameter for "position" (similar to String.prototype.indexOf), for consistency an Array.prototype.contains should have the same second "fromIndex" parameter as Array.prototype.indexOf.