tree: a8bca3a6bc08dc944ecb9d4b971fb94480ed0d87 [path history] [tgz]
  1. index.js
  2. license
  3. package.json
  4. readme.md
third_party/devtools/node_modules/array-find-index/readme.md

array-find-index Build Status

ES2015 Array#findIndex() ponyfill

Install

$ npm install --save array-find-index

Usage

const arrayFindIndex = require('array-find-index');

arrayFindIndex(['rainbow', 'unicorn', 'pony'], x => x === 'unicorn');
//=> 1

API

Same as Array#findIndex(), but with the input array as the first argument.

License

MIT © Sindre Sorhus