Init
The init function/method sets up a table using a key name and a value. Here, we will go through both a simple example on basic node projects and a discord.js example.
Example:
const db = require('hive-db');
db.init('bio',{age:'21', name:'Lason'});
db.get('bio');
// output => {age:'21', name:'Lason'}
db.get('bio.age');
// output => 21
db.get('bio.name');
// output => Lason
Last updated
Was this helpful?