New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

formatarc

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

formatarc

Convert JSON, YAML, and CSV from the terminal. Browser-based version at formatarc.com.

latest
Source
npmnpm
Version
0.1.0
Version published
Maintainers
1
Created
Source

formatarc

Convert JSON, YAML, and CSV from the terminal. No config, no dependencies to manage — just pipe or pass your data.

Web version → formatarc.com

Install

npm install -g formatarc

Or run directly with npx:

npx formatarc json-format '{"a":1}'

Usage

formatarc <tool> [input or file]
cat file | formatarc <tool>

Tools

CommandDescription
json-formatPretty-print JSON
yaml-to-jsonConvert YAML to JSON
json-to-yamlConvert JSON to YAML
csv-to-jsonConvert CSV (with header row) to JSON

Examples

Format JSON:

formatarc json-format '{"name":"FormatArc","tools":["json","yaml","csv"]}'
{
  "name": "FormatArc",
  "tools": [
    "json",
    "yaml",
    "csv"
  ]
}

Convert a YAML file to JSON:

formatarc yaml-to-json config.yaml

Pipe from curl:

curl -s https://api.example.com/data | formatarc json-format

Convert CSV from stdin:

cat users.csv | formatarc csv-to-json

Programmatic API

import { convert } from "formatarc";

const result = convert("json-format", '{"a":1}');
console.log(result.output);
// {
//   "a": 1
// }

convert(tool, input)

Returns { output: string, error: string }.

  • output — the converted result (empty string on error)
  • error — error message (empty string on success)

Web Version

For a browser-based experience with no signup and no data upload:

formatarc.com

  • JSON Formatter, YAML ↔ JSON, CSV → JSON
  • Runs entirely in the browser
  • Multilingual (English / Japanese)

License

MIT

Keywords

json

FAQs

Package last updated on 20 Mar 2026

Did you know?

Socket

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.

Install

Related posts