1.2.1 • Published 4 years ago

ceseve v1.2.1

Weekly downloads
9
License
MIT
Repository
github
Last release
4 years ago

Build Status install size

ceseve

Convert array of data to CSV file

Install

$ npm install ceseve

Usage

const csv = require('ceseve');

const data = [
  { title: "foo", property: "bar" },
  { title: "foo_2", property: "bar_2" }
];

const csvDocument = csv(data);
// csv:
//  title,property
//  foo,bar
//  foo_2,bar_2

You can specify options object:

const csvDocument = csv(data, {
  separator: ';',
});
// csv:
//  title;property
//  foo;bar
//  foo_2;bar_2
## License
MIT © [Carlos Azaustre](https://carlosazaustre.es)