JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 109632
  • Score
    100M100P100Q163847F
  • License MIT

Fast CSV parser

Package Exports

  • neat-csv

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (neat-csv) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

neat-csv

Fast CSV parser

Convenience wrapper around the super-fast streaming csv-parser module. Use that one if you want streamed parsing.

Parsing-related issues should be reported to csv-parser.

Install

$ npm install neat-csv

Usage

const neatCsv = require('neat-csv');

const csv = 'type,part\nunicorn,horn\nrainbow,pink';

(async () => {
    console.log(await neatCsv(csv));
    //=> [{type: 'unicorn', part: 'horn'}, {type: 'rainbow', part: 'pink'}]
})();

API

neatCsv(data, options?)

Returns a Promise<object[]> with the parsed CSV.

data

Type: string | Buffer | stream.Readable

CSV data to parse.

options

Type: object

See the csv-parser options.