You can setup using with commonjs and ESM module
Last updated 5 months ago
const { Database } = require("esosdb"); const db = new Database({ path: "./esosdb/db.json",//you can write the path of any file you want space: 2//it's about readability cf. ** })
import { Database } from "esosdb"; const db = new Database({ path: "./esosdb/db.json", space: 2//it's about readability cf. ** })
set() - You can set new data
get() - You can get data
getAll() - You can get all data
push() - You can add new data to an array
unpush() - You can remove data from an array
delete() - You can remove data
deleteAll() - You can remove all data