xr-easy-json
v1.0.3
Published
easy json database for new coders
Downloads
2
Maintainers
Readme
xr-easy-json
Example
const Data = require('xr-easy-json')
const db = new Data("./db.xr")
// Set data
db.set("hello.man", "Hello") // Hello
// Get data
db.get("hello.man") // Hello
// Fetch data
db.fetch("hello.man") // Hello
// Has data
db.has("hello.man") // true
// Delete data
db.delete("hello.man")
db.get("hello.man") // undefined
db.has("hello.man") // false
// Array data
db.set("list", [ "apple", "milk" ])
db.push("list", "bread") // ["apple", "milk", "bread"]
// Fetch all datas
db.all()
// Clear data
db.clear()