Fast CSV parser
Convenience wrapper around the super-fast streaming csv-parser
module. Use that one if you want streamed parsing.
$ npm install neat-csv
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'}]
})();
Returns a Promise<Object[]>
with the parsed CSV.
Type: string
Buffer
Stream
CSV to parse.
Type: Object
See the csv-parser
options.
MIT © Sindre Sorhus