{"_id":"unique-by","_rev":"4576660","name":"unique-by","description":"Create a unique array of objects","dist-tags":{"latest":"1.0.0"},"maintainers":[{"name":"mlmorg","email":"matt@mlmorg.com"}],"time":{"modified":"2026-04-10T15:44:54.000Z","created":"2015-04-19T01:20:13.432Z","1.0.0":"2015-04-19T01:20:13.432Z"},"users":{},"author":{"name":"Matt Morgan","email":"matt@mlmorg.com"},"repository":{"type":"git","url":"git://github.com/mlmorg/unique-by.git"},"versions":{"1.0.0":{"name":"unique-by","version":"1.0.0","description":"Create a unique array of objects","keywords":[],"author":{"name":"Matt Morgan","email":"matt@mlmorg.com"},"repository":{"type":"git","url":"git://github.com/mlmorg/unique-by.git"},"main":"index.js","homepage":"https://github.com/mlmorg/unique-by","bugs":{"url":"https://github.com/mlmorg/unique-by/issues","email":"matt@mlmorg.com"},"contributors":[{"name":"Matt Morgan"}],"dependencies":{},"devDependencies":{"coveralls":"^2.0.0","istanbul":"^0.3.0","itape":"^1.0.0","lint-trap":"^1.0.0","opn":"^1.0.0","process":"^0.10.1","tape":"^3.4.0"},"licenses":[{"type":"MIT","url":"http://github.com/mlmorg/unique-by/raw/master/LICENSE"}],"scripts":{"check-cover":"istanbul check-coverage --branches=100 --lines=100 --functions=100","check-ls":"npm ls 1>/dev/null","cover":"npm run test-cover -s && npm run check-cover -s","lint":"lint-trap .","test":"npm run check-ls -s && npm run lint -s && npm run cover -s","test-cover":"istanbul cover --report html --print detail -- test/index.js","trace":"itape test/index.js --trace","travis":"npm run cover -s && istanbul report lcov && ((cat coverage/lcov.info | coveralls) || exit 0)","view-cover":"opn ./coverage/index.html"},"engines":{"node":">= 0.10.x"},"pre-commit.silent":true,"itape":{"trace":{"debuglog":["eachfile"],"leakedHandles":{"timeout":5001,"debugSockets":true},"formatStack":true}},"gitHead":"117fc3888a81ac48894bf37f19957687fdf1855e","_id":"unique-by@1.0.0","_shasum":"5220c86ba7bc572fb713ad74651470cb644212bd","_from":".","_npmVersion":"2.7.6","_nodeVersion":"0.10.26","_npmUser":{"name":"mlmorg","email":"matt@mlmorg.com"},"dist":{"shasum":"5220c86ba7bc572fb713ad74651470cb644212bd","size":2686,"noattachment":false,"key":"/unique-by/-/unique-by-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/unique-by/download/unique-by-1.0.0.tgz"},"maintainers":[{"name":"mlmorg","email":"matt@mlmorg.com"}],"directories":{},"_cnpmcore_publish_time":"2021-12-23T18:33:31.661Z","publish_time":1429406413432,"_cnpm_publish_time":1429406413432}},"readme":"# unique-by\n\n[![build status][build-png]][build]\n[![Davis Dependency status][dep-png]][dep]\n[![NPM][npm-png]][npm]\n\nCreate a unique array of objects.\n\n## Example\n\n```js\nvar uniqueBy = require('unique-by');\n\n// With a function\nuniqueBy(arr, function getValue(obj) {\n  return obj.someKey;\n});\n\n// With a key string\nuniqueBy(arr, 'someKey');\n```\n\n## Installation\n\n`npm install unique-by`\n\n## Tests\n\n`npm test`\n\n## NPM scripts\n\n - `npm run cover` This runs the tests with code coverage\n - `npm run lint` This will run the linter on your code\n - `npm test` This will run the tests.\n - `npm run trace` This will run your tests in tracing mode.\n - `npm run travis` This is run by travis.CI to run your tests\n - `npm run view-cover` This will show code coverage in a browser\n\n## Contributors\n\n - Matt Morgan\n\n## MIT Licenced\n\n  [build-png]: https://secure.travis-ci.org/mlmorg/unique-by.png\n  [build]: https://travis-ci.org/mlmorg/unique-by\n  [dep-png]: https://david-dm.org/mlmorg/unique-by.png\n  [dep]: https://david-dm.org/mlmorg/unique-by\n  [npm-png]: https://nodei.co/npm/unique-by.png?stars&downloads\n  [npm]: https://nodei.co/npm/unique-by\n","_attachments":{},"homepage":"https://github.com/mlmorg/unique-by","bugs":{"url":"https://github.com/mlmorg/unique-by/issues","email":"matt@mlmorg.com"}}