{"_id":"find-index","_rev":"71790","name":"find-index","description":"finds an item in an array matching a predicate function, and returns its index","dist-tags":{"latest":"1.1.1"},"maintainers":[{"name":"jsdf","email":"james@jsdf.co"}],"time":{"modified":"2021-06-03T10:23:36.000Z","created":"2014-06-29T10:55:46.649Z","1.1.1":"2019-02-12T17:24:28.786Z","1.1.0":"2015-05-14T22:44:52.112Z","1.0.1":"2015-05-14T21:59:54.825Z","1.0.0":"2015-05-13T12:57:25.659Z","0.1.1":"2014-06-29T11:09:13.030Z","0.1.0":"2014-06-29T10:55:46.649Z"},"users":{"itonyyo":true},"author":{"name":"James Friend","email":"james@jsdf.co","url":"http://jsdf.co/"},"repository":{"type":"git","url":"git://github.com/jsdf/find-index.git"},"versions":{"1.1.1":{"name":"find-index","version":"1.1.1","description":"finds an item in an array matching a predicate function, and returns its index","main":"index.js","keywords":["array","findindex","es6","es2015","ponyfill","polyfill","find"],"scripts":{"test":"tap test"},"devDependencies":{"array-findindex":"0.1.0","lodash.findindex":"^4.6.0","tap":"^1.0.4"},"homepage":"https://github.com/jsdf/find-index","bugs":{"url":"https://github.com/jsdf/find-index/issues"},"repository":{"type":"git","url":"git://github.com/jsdf/find-index.git"},"author":{"name":"James Friend","email":"james@jsdf.co","url":"http://jsdf.co/"},"license":"MIT","gitHead":"41eb0dc94b621851158b95cb95c56334b82e4209","_id":"find-index@1.1.1","_npmVersion":"6.4.1","_nodeVersion":"10.15.0","_npmUser":{"name":"jsdf","email":"james@jsdf.co"},"dist":{"shasum":"4b221f8d46b7f8bea33d8faed953f3ca7a081cbc","size":2698,"noattachment":false,"key":"/find-index/-/find-index-1.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/find-index/download/find-index-1.1.1.tgz"},"maintainers":[{"name":"jsdf","email":"james@jsdf.co"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/find-index_1.1.1_1549992268645_0.21081970359082502"},"_hasShrinkwrap":false,"publish_time":1549992268786,"_cnpm_publish_time":1549992268786},"1.1.0":{"name":"find-index","version":"1.1.0","description":"finds an item in an array matching a predicate function, and returns its index","main":"index.js","keywords":["array","findindex","es6","es2015","ponyfill","polyfill","find"],"scripts":{"test":"tap test"},"devDependencies":{"array-findindex":"0.1.0","lodash.findindex":"3.2.0","tap":"^1.0.4"},"homepage":"https://github.com/jsdf/find-index","bugs":{"url":"https://github.com/jsdf/find-index/issues"},"repository":{"type":"git","url":"git://github.com/jsdf/find-index.git"},"author":{"name":"James Friend","email":"james@jsdf.co","url":"http://jsdf.co/"},"license":"MIT","gitHead":"0a59f236cb89df712475d57c811018b8421b8bf6","_id":"find-index@1.1.0","_shasum":"53007c79cd30040d6816d79458e8837d5c5705ef","_from":".","_npmVersion":"2.4.1","_nodeVersion":"0.10.26","_npmUser":{"name":"jsdf","email":"james@jsdf.co"},"maintainers":[{"name":"jsdf","email":"james@jsdf.co"}],"dist":{"shasum":"53007c79cd30040d6816d79458e8837d5c5705ef","size":2025,"noattachment":false,"key":"/find-index/-/find-index-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/find-index/download/find-index-1.1.0.tgz"},"directories":{},"publish_time":1431643492112,"_cnpm_publish_time":1431643492112,"_hasShrinkwrap":false},"1.0.1":{"name":"find-index","version":"1.0.1","description":"finds an item in an array matching a predicate function, and returns its index","main":"index.js","keywords":["array","findindex","es6","es2015","ponyfill","polyfill","find"],"scripts":{"test":"tap test"},"devDependencies":{"array-findindex":"0.1.0","lodash.findindex":"3.2.0","tap":"^1.0.4"},"homepage":"https://github.com/jsdf/find-index","bugs":{"url":"https://github.com/jsdf/find-index/issues"},"repository":{"type":"git","url":"git://github.com/jsdf/find-index.git"},"author":{"name":"James Friend","email":"james@jsdf.co","url":"http://jsdf.co/"},"license":"MIT","gitHead":"91f56be3955d2faf66eeacd95e8e47f64ec25113","_id":"find-index@1.0.1","_shasum":"7ae901e208411cbb9de045a6fec7fca105924fad","_from":".","_npmVersion":"2.4.1","_nodeVersion":"0.10.26","_npmUser":{"name":"jsdf","email":"james@jsdf.co"},"maintainers":[{"name":"jsdf","email":"james@jsdf.co"}],"dist":{"shasum":"7ae901e208411cbb9de045a6fec7fca105924fad","size":1900,"noattachment":false,"key":"/find-index/-/find-index-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/find-index/download/find-index-1.0.1.tgz"},"directories":{},"publish_time":1431640794825,"_cnpm_publish_time":1431640794825,"_hasShrinkwrap":false},"1.0.0":{"name":"find-index","version":"1.0.0","description":"finds an item in an array matching a predicate function, and returns its index","main":"index.js","keywords":["array","findindex","es6","es2015","ponyfill","polyfill","find"],"files":["index.js","last.js"],"scripts":{"test":"tap test"},"devDependencies":{"array-findindex":"0.1.0","lodash.findindex":"3.2.0","tap":"^1.0.4"},"homepage":"https://github.com/jsdf/find-index","bugs":{"url":"https://github.com/jsdf/find-index/issues"},"repository":{"type":"git","url":"git://github.com/jsdf/find-index.git"},"author":{"name":"James Friend","email":"james@jsdf.co","url":"http://jsdf.co/"},"license":"MIT","gitHead":"d61cad87418f82ff4c3f775f79f380967503e7f2","_id":"find-index@1.0.0","_shasum":"8ad7429102808fbd67e0252714b7c1702767a76b","_from":".","_npmVersion":"2.4.1","_nodeVersion":"0.10.26","_npmUser":{"name":"jsdf","email":"james@jsdf.co"},"maintainers":[{"name":"jsdf","email":"james@jsdf.co"}],"dist":{"shasum":"8ad7429102808fbd67e0252714b7c1702767a76b","size":1171,"noattachment":false,"key":"/find-index/-/find-index-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/find-index/download/find-index-1.0.0.tgz"},"directories":{},"publish_time":1431521845659,"_cnpm_publish_time":1431521845659,"deprecated":"broken. install 1.0.1","_hasShrinkwrap":false},"0.1.1":{"name":"find-index","version":"0.1.1","description":"finds an item in an array matching a predicate function, and returns its index","main":"index.js","keywords":["array","findindex"],"files":["index.js","last.js"],"scripts":{"test":"node test/test"},"homepage":"https://github.com/jsdf/find-index","bugs":{"url":"https://github.com/jsdf/find-index/issues"},"repository":{"type":"git","url":"git://github.com/jsdf/find-index.git"},"author":{"name":"James Friend","email":"james@jsdf.co","url":"http://jsdf.co/"},"license":"MIT","_id":"find-index@0.1.1","dist":{"shasum":"675d358b2ca3892d795a1ab47232f8b6e2e0dde4","size":1087,"noattachment":false,"key":"/find-index/-/find-index-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/find-index/download/find-index-0.1.1.tgz"},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"jsdf","email":"james@jsdf.co"},"maintainers":[{"name":"jsdf","email":"james@jsdf.co"}],"directories":{},"publish_time":1404040153030,"_cnpm_publish_time":1404040153030,"_hasShrinkwrap":false},"0.1.0":{"name":"find-index","version":"0.1.0","description":"finds an item in an array matching a predicate function, and returns its index","main":"index.js","keywords":["array","findindex"],"files":["index.js","last.js"],"scripts":{"test":"node test/test"},"homepage":"https://github.com/jsdf/find-index","bugs":{"url":"https://github.com/jsdf/find-index/issues"},"repository":{"type":"git","url":"git://github.com/jsdf/find-index.git"},"author":{"name":"James Friend","email":"james@jsdf.co","url":"http://jsdf.co/"},"license":"MIT","_id":"find-index@0.1.0","dist":{"shasum":"e59a11b733558be5b59312a77106a65144dd1641","size":1095,"noattachment":false,"key":"/find-index/-/find-index-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/find-index/download/find-index-0.1.0.tgz"},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"jsdf","email":"james@jsdf.co"},"maintainers":[{"name":"jsdf","email":"james@jsdf.co"}],"directories":{},"publish_time":1404039346649,"_cnpm_publish_time":1404039346649,"_hasShrinkwrap":false}},"readme":"\n# find-index\n\nAn implementation of the ES6 method `Array.prototype.findIndex` as a standalone module and a \n[*ponyfill*](https://ponyfill.com).\n\nFinds an item in an array matching a predicate function, and returns its index.\n\nFast both when `thisArg` is used and also when it isn't.\n\n### usage\n\n```bash\nnpm install find-index\n```\n\n```js\nvar findIndex = require('find-index/findIndex')\nvar findIndex = require('find-index/ponyfill') // will use native Array#findIndex if available.\nvar findLastIndex = require('find-index/findLastIndex') // search backwards from end\n```\n    findIndex(array, callback[, thisArg])\n    findLastIndex(array, callback[, thisArg])\n    Parameters:\n      array\n        The array to operate on.\n      callback\n        Function to execute on each value in the array, taking three arguments:\n          element\n            The current element being processed in the array.\n          index\n            The index of the current element being processed in the array.\n          array\n            The array findIndex was called upon.\n      thisArg\n        Object to use as this when executing callback.\n\nBased on [array-findindex](https://www.npmjs.org/package/array-findindex)\n\n### performance\n\n```bash\n$ iojs --harmony_arrays perf/benchmark.js\n\nnative Array.prototype.findIndex: 6347ms\nfindIndex: 1633ms\nfindIndex ponyfill: 6384ms\nfindLastIndex: 1508ms\nnpm lodash.findindex: 2900ms\nnpm array-findindex: 3512ms\n```\n","_attachments":{},"homepage":"https://github.com/jsdf/find-index","bugs":{"url":"https://github.com/jsdf/find-index/issues"},"license":"MIT"}