30 Eylül 2026 Çarşamba

JSON Çeşitleri

Giriş
Açıklaması şöyle
There's a whole ecosystem of JSON-adjacent formats that have emerged over the years, each extending or modifying the base specification to solve problems the original format wasn't designed for.
JSONL  - JSON Lines
Açıklaması şöyle. Streaming ve memory problemini çözer
JSONL is multiple independent JSON objects, one per line. Each line is a complete, valid JSON record. A thousand records means a thousand lines, each standing alone.
Örnek
Şöyle yaparız
// Regular JSON - one structure
{
  "records": [
    {"id": 1, "name": "Alice", "status": "active"},
    {"id": 2, "name": "Bob", "status": "inactive"},
    {"id": 3, "name": "Carol", "status": "active"}
  ]
}
// JSONL - one record per line
{"id": 1, "name": "Alice", "status": "active"}
{"id": 2, "name": "Bob", "status": "inactive"}
{"id": 3, "name": "Carol", "status": "active"}

JSON5 ve JSONC - JSON with Comments
Açıklaması şöyle
Allows comments and trailing commas for more forgiving configuration files. JSONC (JSON with comments, used by VSCode) does something similar.
BISON - Binary JSON
Açıklaması şöyle
Powers MongoDB's internals.
EJSON (Extended JSON)
Açıklaması şöyle
Adds additional type support. 
GeoJSON
Açıklaması şöyle
Structures geographic data.



Hiç yorum yok:

Yorum Gönder