zemirco / json2csv

Convert json to csv with column titles
http://zemirco.github.io/json2csv
MIT License
2.72k stars 363 forks source link

Is it possible to append data with previous csv file? #130

Closed shaishab-duet closed 8 years ago

knownasilya commented 8 years ago

https://github.com/zemirco/json2csv#appending-to-existing-csv

shaishab-duet commented 8 years ago

I used this code to write in csv file

var csv = json2csv({ data: myCars, fields: fields });

fs.writeFile('file.csv', csv, function(err) { if (err) throw err; console.log('file saved'); });

so how to append data second time with file.csv ? @knownasilya can you help me pls?

knownasilya commented 8 years ago

Have a look at this PR https://github.com/zemirco/json2csv/pull/128/files

rjcorwin commented 8 years ago

@shaishab-duet I'm not sure if I'll have time to finish up that PR. Feel free to take the reigns if you do.