hey hi guys how do you create a new branch with the database ?? ie :
var EasyDB = require('easydb')
var db = new EasyDB('file.json')
db.ready = function(){
//Print file.json value
console.log(db.value)
//Manipulate db.v object as you want
db.value.a = []
db.value.a.hello ="world"
//Write db.value to file.json
db.write(function(){
console.log(db.value);
})
}
and the expected output as :
but when I try the code I get the console output correctly
but in the file.json I get
hey hi guys how do you create a new branch with the database ?? ie :
and the expected output as :
{ a:[ hello :"world" ] }but when I try the code I get the console output correctly
but in the file.json I get
{"a":[ ]}