Tree (data format)
From EverybodyWiki Bios & Wiki
User readable binary-compatible streaming hierarchical data format. A simple alternative to JSON, YAML, INI, TOML, partially XML etc.
Features
- No escaping.
- Multiline text support.
- Minimal markup.
- Streaming processing.
- Binary-safe.
- Extensible data model.
- Unlimited hierarchy.
Example
article
title en \Hello world
description \Hello World!
article
title
en \Complex example
ru \Сложный пример
description
\This is multiline raw binary data
\Escaping isn't required \("_")/Comparison
| XML | JSON | YAML | TOML | Tree | |
|---|---|---|---|---|---|
| Size (non minified, approximate assessment) | 195% | 140% | 125% | 110% | 100% |
| Complexity (grammar patterns count) | 90 | 30 | 210 | 90 | 10 |
| Well readability | ❌ | ❌ | ✅ | ✅ | ✅ |
| Required escaping for special chars | ❌ | ❌ | ❌ | ❌ | ✅ |
| Streaming processing by design | ❌ | ❌ | ✅ | ✅ | ✅ |
| Extensibility to represent any data model | ✅ | ❌ | ✅ | ❌ | ✅ |
| Broad support by langs and tools | ✅ | ✅ | ✅ | ❌ | ❌ |
More info
References
- Custom language with sourcemaps support by half hour @ HolyJS'21
- Tree - a single AST to rule over all @ PiterJS (Same @ Undefined)
This article "Tree (data format)" is from Wikipedia. The list of its authors can be seen in its historical and/or the page Edithistory:Tree (data format). Articles copied from Draft Namespace on Wikipedia could be seen on the Draft Namespace of Wikipedia and not main one.
