Formats
JSON ↔ YAML
Convert between JSON and YAML formats.
How to use it
- Open Devly from the wrench in your menu bar, or press ⌃⌥⌘D. Press ⌘P, type JSON ↔ YAML and press Return.
- Choose To YAML or To JSON at the top.
- Paste or type your text into Input.
- Adjust the Options on the right if you need to. The defaults are listed below.
- Press To YAML, or ⌘↵.
- To go the other way, press Swap or ⌘S. The output moves into the input.
- Use Copy or ⇧⌘C to copy the result. ⌘L clears everything.
Options
| Option | Values | Default |
|---|---|---|
| Indent SpacesNumber of spaces for indentation | 1–8 | 2 |
| Sort keysSort keys alphabetically | On or off | Off |
Example
Real output from Devly, with the default options.
Input
{"name":"Devly","version":"2.3.0","tools":65,"offline":true,"price":"$4.99 once","categories":["Encoding","Hashing","Formats","Web Dev","Text","Dev Utils","Graphics"]}
name: Devly
version: 2.3.0
tools: 65
offline: true
price: $4.99 once
categories:
- Encoding
- Hashing
- Formats
- Web Dev
- Text
- Dev Utils
- Graphics
From Terminal
With the free command-line tool installed:
Terminal
devly json2yaml --path input.txt # or pipe text in pbpaste | devly json2yaml
Quick Switch also finds it by: json, yaml, yml, convert, transform.
More Formats tools
JSON FormatterFormat, validate, and minify JSON with syntax highlightingJSON Path QueryQuery JSON data using JSONPath expressionsYAML FormatterFormat, validate, and beautify YAML documentsXML FormatterFormat, validate, and beautify XML documentsXML ↔ JSONConvert between XML and JSON formatsCSV → JSONConvert CSV data to JSON format