json2txttree
Python code that converts JSON data to tree-like output for documentation or pretty printing
Usage
import json
from json2txttree import json2txttree
# Load json data
with open('sample.json', 'r') as f:
jsonData = json.load(f)
# Pretty print json hierarchy as a tree
print(json2txttree(jsonData))
└─ (object)
├─ "name" (string)
├─ "age" (number)
├─ "languages" (array)
│ └─ (string)
├─ "subjects" (object)
│ ├─ "Math" (number)
│ └─ "Science" (number)
└─ "ids" (array)
└─ (object)
├─ "name" (string)
└─ "number" (string)
0.1.0 (2022-03-18)
Initial release.
Metadata
Release files for json2txttree 1.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| json2txttree-1.0.4.tar.gz | 3.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| json2txttree-1.0.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 7.2 kB
Release files / json2txttree-1.0.4.tar.gz
| Download URL | json2txttree-1.0.4.tar.gz |
|---|---|
| Size | 3.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1a773ee85ac3b3de7ae0db1ec3fe82133f200a10ecc049f5e8009adb310e368e
|
|
BLAKE2b-256 checksum How to use checksums |
5845b25b7e79b7f13f81a7720bf78f8d4959c095d4518bf3255af27aec437ba2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.6.9
|
Release files / json2txttree-1.0.4-py3-none-any.whl
| Download URL | json2txttree-1.0.4-py3-none-any.whl |
|---|---|
| Size | 3.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
606e0f0009972ee61d86bc80dc98b1943f530900cb766a9cda09ed700446a3c4
|
|
BLAKE2b-256 checksum How to use checksums |
54527556620b2d025ee9a95c4b168f63b57c69e343a6e19d3675854b9090ae46
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.6.9
|