JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 163577
  • Score
    100M100P100Q157791F
  • License Unlicense

ES7 async-await wrapper for the csv package.

Package Exports

  • async-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 (async-csv) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

ES7 async wrapper for csv package

This is a wrapper for the popular csv package in NPM that can be used with the ES7 async-await pattern, instead of using callbacks.

Documentation

For all documentation, please see the documentation for the csv package.

Usage examples

All parameters are the same as for the functions in the csv module, except that you need to omit the callback parameter.

If there is any error returned by the csv package, an exception will be thrown.

const csv = require('async-csv');

let result1 = await csv.generate(options);
let result2 = await csv.parse(input, options);
let result3 = await csv.transform(data, handler, options); // `options` are not required
let result4 = await csv.stringify(data, options); // `options` are not required

Feedback

Feedback, bug reports and pull requests are welcome. See the linked github repository.