csvtoyaml

1.0.6 • Public • Published

csvtoyaml

Convert csv files to yaml.

Build Status

Installation

npm install csvtoyaml --save

Use

csvtoyaml returns a Promise so you can manipulate the yaml string in the then method. Here's an example of writing the yaml string to the disk.

const csvtoyaml = require('csvtoyaml');
const fs = require('fs');
 
csvtoyaml('${__dirname}/myData.csv')
.then(yaml => {
  fs.writeFile('${__dirname}/myData.yml', yaml);
})
.catch(e => {
  console.error(e);
});

Readme

Keywords

Package Sidebar

Install

npm i csvtoyaml

Weekly Downloads

47

Version

1.0.6

License

MIT

Unpacked Size

2.99 kB

Total Files

8

Last publish

Collaborators

  • timellison