{"version":"5.2.0","name":"csv-parse","description":"CSV parsing implementing the Node.js `stream.Transform` API","keywords":["csv","parse","parser","convert","tsv","stream"],"author":{"name":"David Worms","email":"david@adaltas.com","url":"https://www.adaltas.com"},"contributors":[{"name":"David Worms","email":"david@adaltas.com","url":"https://www.adaltas.com"},{"name":"Will White","url":"https://github.com/willwhite"},{"name":"Justin Latimer","url":"https://github.com/justinlatimer"},{"name":"jonseymour","url":"https://github.com/jonseymour"},{"name":"pascalopitz","url":"https://github.com/pascalopitz"},{"name":"Josh Pschorr","url":"https://github.com/jpschorr"},{"name":"Elad Ben-Israel","url":"https://github.com/eladb"},{"name":"Philippe Plantier","url":"https://github.com/phipla"},{"name":"Tim Oxley","url":"https://github.com/timoxley"},{"name":"Damon Oehlman","url":"https://github.com/DamonOehlman"},{"name":"Alexandru Topliceanu","url":"https://github.com/topliceanu"},{"name":"Visup","url":"https://github.com/visup"},{"name":"Edmund von der Burg","url":"https://github.com/evdb"},{"name":"Douglas Christopher Wilson","url":"https://github.com/dougwilson"},{"name":"Joe Eaves","url":"https://github.com/Joeasaurus"},{"name":"Mark Stosberg","url":"https://github.com/markstos"}],"exports":{".":{"import":"./lib/index.js","require":"./dist/cjs/index.cjs"},"./sync":{"import":"./lib/sync.js","require":"./dist/cjs/sync.cjs"},"./browser/esm":"./dist/esm/index.js","./browser/esm/sync":"./dist/esm/sync.js"},"devDependencies":{"@rollup/plugin-eslint":"^8.0.2","@rollup/plugin-node-resolve":"^13.3.0","@types/mocha":"^9.1.1","@types/node":"^17.0.35","coffeelint":"^2.1.0","coffeescript":"^2.7.0","csv-generate":"^4.1.0","csv-spectrum":"^1.0.0","each":"^1.2.2","eslint":"^8.16.0","mocha":"^10.0.0","pad":"^3.2.0","rollup":"^2.74.1","rollup-plugin-node-builtins":"^2.1.2","rollup-plugin-node-globals":"^1.4.0","should":"^13.2.3","stream-transform":"^3.1.0","ts-node":"^10.8.0","typescript":"^4.6.4"},"homepage":"https://csv.js.org/parse/","license":"MIT","main":"./dist/cjs/index.cjs","mocha":{"inline-diffs":true,"loader":"./test/loaders/all.js","recursive":true,"reporter":"spec","require":["should"],"throw-deprecation":true,"timeout":40000},"repository":{"type":"git","url":"git+https://github.com/adaltas/node-csv.git","directory":"packages/csv-parse"},"scripts":{"build":"npm run build:rollup && npm run build:ts","build:rollup":"npx rollup -c","build:ts":"cp lib/*.ts dist/cjs && cp lib/*.ts dist/esm","lint":"npm run lint:lib && npm run lint:samples && npm run lint:test","lint:lib":"eslint --fix lib/*.js","lint:samples":"eslint --fix samples/*.js","lint:test":"coffeelint --fix test/*.coffee","preversion":"npm run build && git add dist","pretest":"npm run build","test":"mocha 'test/**/*.{coffee,ts}'","test:legacy":"mocha --ignore test/api.web_stream.coffee --loader=./test/loaders/legacy/all.js 'test/**/*.{coffee,ts}'"},"type":"module","types":"dist/esm/index.d.ts","typesVersions":{"*":{".":["dist/esm/index.d.ts"],"sync":["dist/esm/sync.d.ts"],"browser/esm":["dist/esm/index.d.ts"],"browser/esm/sync":["dist/esm/sync.d.ts"]}},"gitHead":"851a129b5c57c5c77e49fee3587a0d4afb91c683","bugs":{"url":"https://github.com/adaltas/node-csv/issues"},"_id":"csv-parse@5.2.0","_nodeVersion":"16.15.1","_npmVersion":"lerna/4.0.0/node@v16.15.1+x64 (linux)","dist":{"integrity":"sha512-ZuLjTp3Qx2gycoB7FKS9q11KgDL3f0wQszTlNOajS3fHa0jypN/zgjmkam+rczX5dXw5z7+KrDW2hWkM4542Ug==","shasum":"492b5ca2e5e87e3672ca834e83ab3a0e2486d5cb","tarball":"http://registry-npm.ywwl.com/csv-parse/download/csv-parse-5.2.0.tgz","fileCount":28,"unpackedSize":1303644,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC+miK6pEff5KJuXy6A20Ts3I/4+mjkMyN+9h1IbJ7zpgIgCCVvzvQSAlXT6S28Wd3v1zi7snoKVm1KJJsYxqXuIuA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiqJ4uACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpYUhAApQKIIvVkHfSUmYPnmkPrr6gevHM2A/y41ITOxup55yUnwa5y\r\nEnRDZxxhYVddaqI7IrEGvsBRj3rUfmTpjJM7ASl2gYsg1cTyMMyHWKE2wZZL\r\neZM2ck//Sx9Mj63yq87mux6FBDwD3zwXrI1y1xaoSssTCWPL8JtKMaw66aO+\r\n1rqVmeYVNR0pkVdQi8SJ5Ir0dMxE05WOLyi3eD1cpkPTa4kwM/w7anA5kR0d\r\nyjxsb/og6tQczHvTGcqE9JNrvsivohDgTl+TrkaHpznrkrWHC/jtM7ry7dKH\r\nKHVhCLmauWb2JbvreGia8MXLUxYUh+8iTHCGIAlfsUDqn5n+WBSR5cFTU3X3\r\ntrJJcSvFYdo6zkfsNjrthyOmLHx9BvP7GKu7Is2sYkv0PMp+XumT/v6P8RNq\r\nqMD0EHJrVr0DC+rR0GONYVokc2u/AeLMeDdfW1S3Rne9oNhmZpYw6X2qOddO\r\nU5pE2tYorAhUU3w1SRSKPOtCCpDdUpSONotUkh9gVknBfMmjpkk2M7AR1fOO\r\nTPoDqEpfoKQsZ6TPXKB91PK6gJz+6DfE2v+L28/Ef76PQ8Q4WSGPIB7JbY/Z\r\n0QXdcca67A+5SzqJIhxfzXjILY5tfB+1q1xt607gSemublPED8CGEnK3M9NN\r\ngba8hqGyhEmHw+nqx7v+oMNXHqb7kTy72K4=\r\n=COjm\r\n-----END PGP SIGNATURE-----\r\n","size":250722,"noattachment":false,"key":"/csv-parse/-/csv-parse-5.2.0.tgz"},"_npmUser":{"name":"david","email":"david@adaltas.com"},"directories":{},"maintainers":[{"name":"david","email":"david@adaltas.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/csv-parse_5.2.0_1655217709925_0.8481212969372625"},"_hasShrinkwrap":false,"readme":"\n# CSV parser for Node.js and the web\n\n[![Build Status](https://img.shields.io/github/actions/workflow/status/adaltas/node-csv/nodejs.yml?branch=master)](https://github.com/adaltas/node-csv/actions)\n[![NPM](https://img.shields.io/npm/dm/csv-parse)](https://www.npmjs.com/package/csv-parse)\n[![NPM](https://img.shields.io/npm/v/csv-parse)](https://www.npmjs.com/package/csv-parse)\n \nThe [`csv-parse` package](https://csv.js.org/parse/) is a parser converting CSV text input into arrays or objects. It is part of the [CSV project](https://csv.js.org/).\n\nIt implements the Node.js [`stream.Transform` API](http://nodejs.org/api/stream.html#stream_class_stream_transform). It also provides a simple callback-based API for convenience. It is both extremely easy to use and powerful. It was first released in 2010 and is used against big data sets by a large community.\n\n## Documentation\n\n* [Project homepage](https://csv.js.org/parse/)\n* [API](https://csv.js.org/parse/api/)\n* [Options](https://csv.js.org/parse/options/)\n* [Info properties](https://csv.js.org/parse/info/)\n* [Common errors](https://csv.js.org/parse/errors/)\n* [Examples](https://csv.js.org/project/examples/)\n\n## Main features\n\n*   Flexible with lot of [options](https://csv.js.org/parse/options/)\n*   Multiple [distributions](https://csv.js.org/parse/distributions/): Node.js, Web, ECMAScript modules and CommonJS\n*   Follow the Node.js streaming API\n*   Simplicity with the optional callback API\n*   Support delimiters, quotes, escape characters and comments\n*   Line breaks discovery\n*   Support big datasets\n*   Complete test coverage and lot of samples for inspiration\n*   No external dependencies\n*   Work nicely with the [csv-generate](https://csv.js.org/generate/), [stream-transform](https://csv.js.org/transform/) and [csv-stringify](https://csv.js.org/stringify/) packages\n*   MIT License\n\n## Usage\n\nRun `npm install csv` to install the full CSV module or run `npm install csv-parse` if you are only interested by the CSV parser.\n\nUse the callback and sync APIs for simplicity or the stream based API for scalability.\n\n## Example\n\nThe [API](https://csv.js.org/parse/api/) is available in multiple flavors. This example illustrates the stream API.\n\n```js\nimport assert from 'assert';\nimport { parse } from 'csv-parse';\n\nconst records = [];\n// Initialize the parser\nconst parser = parse({\n  delimiter: ':'\n});\n// Use the readable stream api to consume records\nparser.on('readable', function(){\n  let record;\n  while ((record = parser.read()) !== null) {\n    records.push(record);\n  }\n});\n// Catch any error\nparser.on('error', function(err){\n  console.error(err.message);\n});\n// Test that the parsed records matched the expected records\nparser.on('end', function(){\n  assert.deepStrictEqual(\n    records,\n    [\n      [ 'root','x','0','0','root','/root','/bin/bash' ],\n      [ 'someone','x','1022','1022','','/home/someone','/bin/bash' ]\n    ]\n  );\n});\n// Write data to the stream\nparser.write(\"root:x:0:0:root:/root:/bin/bash\\n\");\nparser.write(\"someone:x:1022:1022::/home/someone:/bin/bash\\n\");\n// Close the readable stream\nparser.end();\n```\n\n## Contributors\n\nThe project is sponsored by [Adaltas](https://www.adaltas.com), an Big Data consulting firm based in Paris, France.\n\n*   David Worms: <https://github.com/wdavidw>\n","publish_time":1655217710140,"_cnpm_publish_time":1655217710140,"dist-tags":{"latest":"7.0.3"}}