/root of your project
|
+-- ... Your code base
data(the databse root director # Fully customizable)
|
+-- Subdb(ponies)
|
+-- Table(rainbow_dash # Via a JSON format)
|
+-- (Data)
This database is design not to overwrite stuff
Init the database
db.init({
path:"./data/db"
})
.then(()=>{
console.log(`Database init successfully :P`);
})
.catch(error=>{
console.error(error)
})
Create subdb
db.createSubdb("mySubdbName")
.then(dbName=>{
console.log(`My awesome ${dbName} was created :P`);
})
.catch(error=>{
console.error(error)
})
Create table
db.createTable("myTable")
.then(tableName=>{
console.log(`My awesome ${tableName} was created :P`);