2.1.0 • Published 2 years ago

@vedux/vedudb v2.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

VeduDB

VeduDB is a lightweight and simple to use JSON based database (That doesnt corrupt)

Installing VeduDB

npm:

npm i --save @vedux/vedudb

Yarn:

yarn add @vedux/vedudb

How to use VeduDB

let vedudb = require("@vedux/vedudb");
let db = new vedudb("database.json");

(async () => {
  // Make some values with a key
  await db.set("Developer1", "Ducksquaddd");
  await db.set("Developer2", "bqini");

  // Log whatever the value is to this key
  console.log(await db.fetch("Developer1")); // => "Ducksquaddd"

  // I want to get all my stored data
  console.log(await db.fetchAll())) // => { All the db content }

  // I dont like Develper 2
  console.log(await db.remove("Developer2")); // => true

  // I robbed an old lady
  await db.set("money", 250);

  // Then I hacked the CIA
  await db.add("money" 100000);

  // And then i got caught
  await db.subtract("money", 100250)
})();

Discord

Come join the Discord If you would like help with this package!

license

This package is open sourced under the MIT License.

FAQ

2.1.0

2 years ago

2.0.0

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago