An NPM package which can be used to read and convert CSV files to JSON in javaScript.
Install csvinarray
with npm
$ npm install csvinarray
const convert = require('csvinarray');
let jsonData = csvinarray(__dirname + "/sample/example-csv.csv");
// Data in json from the csv file.
It is just one line in order to convert your CSV file to JSON.
There is just one function, Which can be used as this.
let jsonData = csvinarray(__dirname + "/sample/example-csv.csv");
// ^ very important | pwd + Path
// *pwd = present working directory
To run tests, run the following command
$ npm run test
- Waiting for other authors.
If you have any feedback, please reach out to us in the issues sections.