Skip to content

yocontra/neat-csv

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

neat-csv Build Status

Fast CSV parser

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

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(input, [options])

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

input

Type: string Buffer Stream

CSV to parse.

options

Type: Object

See the csv-parser options.

License

MIT © Sindre Sorhus

About

Fast CSV parser

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%