blob: 5b334c369f818b769cd3804d9c5efa7e3d0b1831 [file] [log] [blame]
{
"_args": [
[
{
"raw": "parseurl@~1.3.2",
"scope": null,
"escapedName": "parseurl",
"name": "parseurl",
"rawSpec": "~1.3.2",
"spec": ">=1.3.2 <1.4.0",
"type": "range"
},
"/Users/steveng/repo/cordova/cordova-browser/node_modules/express"
]
],
"_from": "parseurl@>=1.3.2 <1.4.0",
"_id": "parseurl@1.3.2",
"_inCache": true,
"_location": "/parseurl",
"_nodeVersion": "6.11.1",
"_npmOperationalInternal": {
"host": "s3://npm-registry-packages",
"tmp": "tmp/parseurl-1.3.2.tgz_1504992079883_0.05658079497516155"
},
"_npmUser": {
"name": "dougwilson",
"email": "doug@somethingdoug.com"
},
"_npmVersion": "3.10.10",
"_phantomChildren": {},
"_requested": {
"raw": "parseurl@~1.3.2",
"scope": null,
"escapedName": "parseurl",
"name": "parseurl",
"rawSpec": "~1.3.2",
"spec": ">=1.3.2 <1.4.0",
"type": "range"
},
"_requiredBy": [
"/express",
"/finalhandler",
"/serve-static"
],
"_resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.2.tgz",
"_shasum": "fc289d4ed8993119460c156253262cdc8de65bf3",
"_shrinkwrap": null,
"_spec": "parseurl@~1.3.2",
"_where": "/Users/steveng/repo/cordova/cordova-browser/node_modules/express",
"bugs": {
"url": "https://github.com/pillarjs/parseurl/issues"
},
"contributors": [
{
"name": "Douglas Christopher Wilson",
"email": "doug@somethingdoug.com"
},
{
"name": "Jonathan Ong",
"email": "me@jongleberry.com",
"url": "http://jongleberry.com"
}
],
"dependencies": {},
"description": "parse a url with memoization",
"devDependencies": {
"beautify-benchmark": "0.2.4",
"benchmark": "2.1.4",
"eslint": "3.19.0",
"eslint-config-standard": "10.2.1",
"eslint-plugin-import": "2.7.0",
"eslint-plugin-node": "5.1.1",
"eslint-plugin-promise": "3.5.0",
"eslint-plugin-standard": "3.0.1",
"fast-url-parser": "1.1.3",
"istanbul": "0.4.5",
"mocha": "2.5.3"
},
"directories": {},
"dist": {
"shasum": "fc289d4ed8993119460c156253262cdc8de65bf3",
"tarball": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.2.tgz"
},
"engines": {
"node": ">= 0.8"
},
"files": [
"LICENSE",
"HISTORY.md",
"README.md",
"index.js"
],
"gitHead": "0022a009d0973a44ae3849e83112ea4d12ad5b49",
"homepage": "https://github.com/pillarjs/parseurl#readme",
"license": "MIT",
"maintainers": [
{
"name": "dougwilson",
"email": "doug@somethingdoug.com"
}
],
"name": "parseurl",
"optionalDependencies": {},
"readme": "# parseurl\n\n[![NPM Version][npm-image]][npm-url]\n[![NPM Downloads][downloads-image]][downloads-url]\n[![Node.js Version][node-version-image]][node-version-url]\n[![Build Status][travis-image]][travis-url]\n[![Test Coverage][coveralls-image]][coveralls-url]\n\nParse a URL with memoization.\n\n## Install\n\nThis is a [Node.js](https://nodejs.org/en/) module available through the\n[npm registry](https://www.npmjs.com/). Installation is done using the\n[`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):\n\n```sh\n$ npm install parseurl\n```\n\n## API\n\n```js\nvar parseurl = require('parseurl')\n```\n\n### parseurl(req)\n\nParse the URL of the given request object (looks at the `req.url` property)\nand return the result. The result is the same as `url.parse` in Node.js core.\nCalling this function multiple times on the same `req` where `req.url` does\nnot change will return a cached parsed object, rather than parsing again.\n\n### parseurl.original(req)\n\nParse the original URL of the given request object and return the result.\nThis works by trying to parse `req.originalUrl` if it is a string, otherwise\nparses `req.url`. The result is the same as `url.parse` in Node.js core.\nCalling this function multiple times on the same `req` where `req.originalUrl`\ndoes not change will return a cached parsed object, rather than parsing again.\n\n## Benchmark\n\n```bash\n$ npm run-script bench\n\n> parseurl@1.3.2 bench nodejs-parseurl\n> node benchmark/index.js\n\n http_parser@2.7.0\n node@4.8.4\n v8@4.5.103.47\n uv@1.9.1\n zlib@1.2.11\n ares@1.10.1-DEV\n icu@56.1\n modules@46\n openssl@1.0.2k\n\n> node benchmark/fullurl.js\n\n Parsing URL \"http://localhost:8888/foo/bar?user=tj&pet=fluffy\"\n\n 3 tests completed.\n\n fasturl x 1,246,766 ops/sec ±0.74% (188 runs sampled)\n nativeurl x 91,536 ops/sec ±0.54% (189 runs sampled)\n parseurl x 90,645 ops/sec ±0.38% (189 runs sampled)\n\n> node benchmark/pathquery.js\n\n Parsing URL \"/foo/bar?user=tj&pet=fluffy\"\n\n 3 tests completed.\n\n fasturl x 2,077,650 ops/sec ±0.69% (186 runs sampled)\n nativeurl x 638,669 ops/sec ±0.67% (189 runs sampled)\n parseurl x 2,431,842 ops/sec ±0.71% (189 runs sampled)\n\n> node benchmark/samerequest.js\n\n Parsing URL \"/foo/bar?user=tj&pet=fluffy\" on same request object\n\n 3 tests completed.\n\n fasturl x 2,135,391 ops/sec ±0.69% (188 runs sampled)\n nativeurl x 672,809 ops/sec ±3.83% (186 runs sampled)\n parseurl x 11,604,947 ops/sec ±0.70% (189 runs sampled)\n\n> node benchmark/simplepath.js\n\n Parsing URL \"/foo/bar\"\n\n 3 tests completed.\n\n fasturl x 4,961,391 ops/sec ±0.97% (186 runs sampled)\n nativeurl x 914,931 ops/sec ±0.83% (186 runs sampled)\n parseurl x 7,559,196 ops/sec ±0.66% (188 runs sampled)\n\n> node benchmark/slash.js\n\n Parsing URL \"/\"\n\n 3 tests completed.\n\n fasturl x 4,053,379 ops/sec ±0.91% (187 runs sampled)\n nativeurl x 963,999 ops/sec ±0.58% (189 runs sampled)\n parseurl x 11,516,143 ops/sec ±0.58% (188 runs sampled)\n```\n\n## License\n\n [MIT](LICENSE)\n\n[npm-image]: https://img.shields.io/npm/v/parseurl.svg\n[npm-url]: https://npmjs.org/package/parseurl\n[node-version-image]: https://img.shields.io/node/v/parseurl.svg\n[node-version-url]: https://nodejs.org/en/download/\n[travis-image]: https://img.shields.io/travis/pillarjs/parseurl/master.svg\n[travis-url]: https://travis-ci.org/pillarjs/parseurl\n[coveralls-image]: https://img.shields.io/coveralls/pillarjs/parseurl/master.svg\n[coveralls-url]: https://coveralls.io/r/pillarjs/parseurl?branch=master\n[downloads-image]: https://img.shields.io/npm/dm/parseurl.svg\n[downloads-url]: https://npmjs.org/package/parseurl\n",
"readmeFilename": "README.md",
"repository": {
"type": "git",
"url": "git+https://github.com/pillarjs/parseurl.git"
},
"scripts": {
"bench": "node benchmark/index.js",
"lint": "eslint .",
"test": "mocha --check-leaks --bail --reporter spec test/",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --reporter dot test/",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --reporter spec test/"
},
"version": "1.3.2"
}