https://github.com/elliotgao2/flatjson
Flatten JSON.
https://github.com/elliotgao2/flatjson
flatten json
Last synced: about 2 months ago
JSON representation
Flatten JSON.
- Host: GitHub
- URL: https://github.com/elliotgao2/flatjson
- Owner: elliotgao2
- Created: 2019-09-06T08:10:10.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-09-06T08:24:22.000Z (over 5 years ago)
- Last Synced: 2025-01-20T08:49:59.382Z (3 months ago)
- Topics: flatten, json
- Language: Python
- Homepage:
- Size: 2.93 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Flatjson
Flatten JSON.
## Installation
`pip install flatjson`
## Usage
```python
import flatjsondata = {
"list":[{"a":1},{"b":True}],
"dict":{"c":1.1,"d":{"e":"string"}}
}
flatjson.dumps(data)# {'list[0].a': 1, 'list[1].b': True, 'dict.c': 1.1, 'dict.d.e': 'string'}
```