4 ms·
I was looking for a human-friendly format to store data for a staticly generated website. Stuff like copy, lists, addresses, contact information (so that the re
by dmos62 4y ago
I was looking for a human-friendly format to store data for a staticly generated website. Stuff like copy, lists, addresses, contact information (so that the rendering logic is kept separate).
Landed on NestedText, and apart from it having few implementations, I loved it! https://nestedtext.org/en/stable/ https://nestedtext.org/en/stable/
I did feel like I missed a more popular alternative, because I can't be the only one to want a human-friendly data format.
- AndyKluger 4y agoI'm a huge fan of NestedText, especially as there is no escaping needed ever. If you ever want to use it as a pre-format to generate either TOML, JSON, or YAML, I used the official reference implementation to make a CLI converter between them and NestedText. When generating one of these formats, you can use yamlpath queries to concisely but explicitly apply supported types to data elements. - My CLI converter: https://github.com/AndydeCleyre/nestedtextto https://github.com/AndydeCleyre/nestedtextto - yamlpath info: https://github.com/wwkimball/yamlpath/wiki/Search-Expressions https://github.com/wwkimball/yamlpath/wiki/Search-Expression...
- dmos62 4y agoWow, that's really versatile! Thanks for sharing! `json2nt` seems like a great alternative to `jq .` for pretty printing.