3 ms·
Ask HN: What's your preferred output format?
Do you prefer JSON, XML, Plaintext, CSV, XLS, YAML, etc? And why?
- zzo38computer 6y agoWhat is it supposed to be the output of? I think that it would depend on that SQLite includes an extension to deal with JSON, and the command shell can also deal with CSV, and I also wrote a JSON parser in PostScript, so that means it can easily be used with PostScript codes too now, and of course JavaScript also has JSON built-in.
- JoshTriplett 6y agoDepends heavily on the data. If it's human-readable, read-only, and almost completely unstructured, plaintext. If it's human-readable, read-only, and structured but formatting doesn't matter, HTML. If it's human-readable, read-only, and formatting matters, PDF. If it's intended for humans to read and write via hand-editing, and then subsequently have a machine work with, then TOML. (Never YAML.) If it's fundamentally tabular, CSV. (Never XLS.) If it's an API result from a web API, reluctantly JSON; as much as I'd prefer TOML, JSON is more universal.
- deleted 6y ago[deleted]
- billconan 6y agothis is the best in my opinion https://hjson.github.io/ https://hjson.github.io/ xml is too wordy yaml, well I don't like indentation based formats, hard to see clearly