npm.io
1.0.1 • Published 7 years agoCLI

ndjson2csv

Licence
ISC
Version
1.0.1
Deps
0
Size
2 kB
Vulns
0
Weekly
0

ndjson2csv

CLI tool that turns NDJSON into CSV.

Ignores lines that do not parse as JSON.

Ignores trailing commas so it also works with regular JSON.

JSON properties of the first valid row become the CSV headers column names.

Compatible with JSONL or JSON lines format.

Usage

cat metrics.json | npx ndjson2csv > spreadsheet.csv

Keywords