{
  "_args": [
    [
      {
        "raw": "p-locate@^3.0.0",
        "scope": null,
        "escapedName": "p-locate",
        "name": "p-locate",
        "rawSpec": "^3.0.0",
        "spec": ">=3.0.0 <4.0.0",
        "type": "range"
      },
      "/home/zkochan/src/pnpm/packages/pnpm/node_modules/locate-path"
    ]
  ],
  "_from": "p-locate@>=3.0.0 <4.0.0",
  "_id": "p-locate@3.0.0",
  "_inCache": true,
  "_location": "/p-locate",
  "_nodeVersion": "8.11.2",
  "_npmOperationalInternal": {
    "host": "s3://npm-registry-packages",
    "tmp": "tmp/p-locate_3.0.0_1529066877849_0.3762033584213962"
  },
  "_npmUser": {
    "name": "sindresorhus",
    "email": "sindresorhus@gmail.com"
  },
  "_npmVersion": "5.6.0",
  "_phantomChildren": {},
  "_requested": {
    "raw": "p-locate@^3.0.0",
    "scope": null,
    "escapedName": "p-locate",
    "name": "p-locate",
    "rawSpec": "^3.0.0",
    "spec": ">=3.0.0 <4.0.0",
    "type": "range"
  },
  "_requiredBy": [
    "/locate-path"
  ],
  "_resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz",
  "_shasum": "322d69a05c0264b25997d9f40cd8a891ab0064a4",
  "_shrinkwrap": null,
  "_spec": "p-locate@^3.0.0",
  "_where": "/home/zkochan/src/pnpm/packages/pnpm/node_modules/locate-path",
  "author": {
    "name": "Sindre Sorhus",
    "email": "sindresorhus@gmail.com",
    "url": "sindresorhus.com"
  },
  "bugs": {
    "url": "https://github.com/sindresorhus/p-locate/issues"
  },
  "dependencies": {
    "p-limit": "^2.0.0"
  },
  "description": "Get the first fulfilled promise that satisfies the provided testing function",
  "devDependencies": {
    "ava": "*",
    "delay": "^3.0.0",
    "in-range": "^1.0.0",
    "time-span": "^2.0.0",
    "xo": "*"
  },
  "directories": {},
  "dist": {
    "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==",
    "shasum": "322d69a05c0264b25997d9f40cd8a891ab0064a4",
    "tarball": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz",
    "fileCount": 4,
    "unpackedSize": 5055,
    "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbI7V+CRA9TVsSAnZWagAAmS8P/iJ5wzoShdXBVPfoNY1O\nr0t03ZiQkJ9Ae4XuJU5C5c2Si7lcgGw8sx6C+iAcYX/zWv7mfygNi+C/ADF5\nZuCBwp0hhC2Nott55961FfTiCHTO2/MRApZo2Eg3sl/ru0KglHvRFS5r/ZXb\n634s++vlPvlbFzCDfELeeM8YOxNjYryRhgNQ6UxXIvsU8RffnrMDXVJphnXE\nWuUEmhgCxzSgH8F/C0DblXoAGkp1qwKAY8MmaWgJpvtIvn2JYC/87S3pdSYy\nMngjVE1MTEulUubGKDmO83N1vM45n1r/pMZarNF2GHynO6SWR68JBPIQ+dmn\nFP4iNv+2eJVExkQzg/DKWNwoPSmq3karaEBU6AJtHRxoe8qgxdjPgjMqPZ0a\n5KieVHs/rwPxKL2/qOSfElcZ5lrnXICuoErKMeR5NjYD5o1Q+7DUhwAWzATv\nS7vP0ZdUCS0+Zt/F7vFk24WzOAhiGNK/aL5TtfKYGu9VmBDj1gJNOVHP+/zl\nRWjSFB9rkVoCYxscx+VYERfgAHqldYF2afgTNOVHy0iNOFelldi1oCT3KP0W\nIMyP1lQE+Nz3Z7JdrFIhe+a2N+swjaadfCw2nk2mesCBvYZDNUeTlQ9ao05h\nFHV0pcoqg98mHz3sklz8aj1phUPkIbbzYd9KPMRAobdjvbtwTQDu2hjYsDXv\niPPm\r\n=9PP9\r\n-----END PGP SIGNATURE-----\r\n"
  },
  "engines": {
    "node": ">=6"
  },
  "files": [
    "index.js"
  ],
  "gitHead": "d37f108c0b04779e307b4e7203981caa367bac57",
  "homepage": "https://github.com/sindresorhus/p-locate#readme",
  "keywords": [
    "promise",
    "locate",
    "find",
    "finder",
    "search",
    "searcher",
    "test",
    "array",
    "collection",
    "iterable",
    "iterator",
    "race",
    "fulfilled",
    "fastest",
    "async",
    "await",
    "promises",
    "bluebird"
  ],
  "license": "MIT",
  "maintainers": [
    {
      "name": "sindresorhus",
      "email": "sindresorhus@gmail.com"
    }
  ],
  "name": "p-locate",
  "optionalDependencies": {},
  "readme": "# p-locate [![Build Status](https://travis-ci.org/sindresorhus/p-locate.svg?branch=master)](https://travis-ci.org/sindresorhus/p-locate)\n\n> Get the first fulfilled promise that satisfies the provided testing function\n\nThink of it like an async version of [`Array#find`](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/find).\n\n\n## Install\n\n```\n$ npm install p-locate\n```\n\n\n## Usage\n\nHere we find the first file that exists on disk, in array order.\n\n```js\nconst pathExists = require('path-exists');\nconst pLocate = require('p-locate');\n\nconst files = [\n\t'unicorn.png',\n\t'rainbow.png', // Only this one actually exists on disk\n\t'pony.png'\n];\n\n(async () => {\n\tconst foundPath = await pLocate(files, file => pathExists(file));\n\n\tconsole.log(foundPath);\n\t//=> 'rainbow'\n})();\n```\n\n*The above is just an example. Use [`locate-path`](https://github.com/sindresorhus/locate-path) if you need this.*\n\n\n## API\n\n### pLocate(input, tester, [options])\n\nReturns a `Promise` that is fulfilled when `tester` resolves to `true` or the iterable is done, or rejects if any of the promises reject. The fulfilled value is the current iterable value or `undefined` if `tester` never resolved to `true`.\n\n#### input\n\nType: `Iterable<Promise|any>`\n\n#### tester(element)\n\nType: `Function`\n\nExpected to return a `Promise<boolean>` or boolean.\n\n#### options\n\nType: `Object`\n\n##### concurrency\n\nType: `number`<br>\nDefault: `Infinity`<br>\nMinimum: `1`\n\nNumber of concurrently pending promises returned by `tester`.\n\n##### preserveOrder\n\nType: `boolean`<br>\nDefault: `true`\n\nPreserve `input` order when searching.\n\nDisable this to improve performance if you don't care about the order.\n\n\n## Related\n\n- [p-map](https://github.com/sindresorhus/p-map) - Map over promises concurrently\n- [p-filter](https://github.com/sindresorhus/p-filter) - Filter promises concurrently\n- [p-any](https://github.com/sindresorhus/p-any) - Wait for any promise to be fulfilled\n- [More…](https://github.com/sindresorhus/promise-fun)\n\n\n## License\n\nMIT © [Sindre Sorhus](https://sindresorhus.com)\n",
  "readmeFilename": "readme.md",
  "repository": {
    "type": "git",
    "url": "git+https://github.com/sindresorhus/p-locate.git"
  },
  "scripts": {
    "test": "xo && ava"
  },
  "version": "3.0.0"
}
