
Security News
Vite+ Joins the Push to Consolidate JavaScript Tooling
Evan You announces Vite+, a commercial, Rust-powered toolchain built on the Vite ecosystem to unify JavaScript development and fund open source.
Stream and CLI to convert CSV to JSON.
Installation of the npm package:
Install globally if you want to use the CLI:
npm install --global csv2json
Install locally if you want to use it as a library:
npm install --save csv2json
Usage: csv2json [OPTIONS] [<input file> [<output file>]]
-d, --dynamic-typing
Convert booleans and numeric to their type instead of strings.
-s <separator>, --separator=<separator>
Field separator to use (default to comma “,”).
-t, --tsv
Use tab as separator, overrides separator flag.
<input file>
CSV file to read data from.
If unspecified or a dash (“-”), use the standard input.
<output file>
JSON file to write data to.
If unspecified or a dash (“-”), use the standard output.
var csv2json = require('csv2json');
var fs = require('fs');
fs.createReadStream('data.csv')
.pipe(csv2json({
// Defaults to comma.
separator: ';'
}))
.pipe(fs.createWriteStream('data.json'));
Contributions are very welcomed, either on the documentation or on the code.
You may:
Thanks to @twilson63 for letting me use the csv2json name on npm.
ISC © Julien Fontanet
FAQs
Stream and CLI to convert CSV to JSON
The npm package csv2json receives a total of 9,578 weekly downloads. As such, csv2json popularity was classified as popular.
We found that csv2json demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Evan You announces Vite+, a commercial, Rust-powered toolchain built on the Vite ecosystem to unify JavaScript development and fund open source.
Security News
Ruby Central’s incident report on the RubyGems.org access dispute sparks backlash from former maintainers and renewed debate over project governance.
Research
/Security News
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.