csvtojsonlite
v1.0.1
Published
convert csv to json
Downloads
2
Readme
csvtojsonLite
convert CSV file to JSON file Installation 1- execute npm install For test 2-execute node demo.js to test it
how to use it ? in the file you want to use it put: var csvtojsonLite= require('csvtojsonLite') csvtojsonLite= new csvtojsonLite() then you can use either csvJson.csvtojsonMod(csvFilePath).then(JsonRes => { console.log(JsonRes)
})
or csvJson.customCsvtojson(csvFilePath).then(JsonRes => { // console.log(JsonRes) fs.writeFile('customer-data.json', JSON.stringify(JsonRes, null, 2), (error) => { if (error) return process.exit(1) console.log('done') process.exit(0) })
})