pip install EasyJSON
EasyJSON is a package i made for people to ease the use of JSON files
from EasyJSON import JSON
db = JSON("JSON_FILE_LOCATION", indent=4)You can now use it like any other db, but its a json!
db.add('Water', 'Lava')
db.query.all()
#{"Water": "Lava"}db.edit('Water', 'Air')
db.query.all()
#{"Water": "Air"}db.delete('Water')
db.query.all()
#{}db.reset()
#{}db.add('Water', 'Lava')
db.add('Air', 'Soil')
db.query.all()
#{"Water": "Lava", "Air": "Soil"}db.query.filter_by('Water')
#'Lava'
db.query.filter_by('Lava')
#None