Skip to content

PrismDB is a simple JavaScript key-value store library that provides basic CRUD operations, table-like structures, and saves data to a file.

License

Notifications You must be signed in to change notification settings

phoave/PrisimDB

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PrismDB

videoframe_24582

PrismDB is a simple JavaScript key-value store library that provides basic CRUD operations, table-like structures, and saves data to a file.

Installation

You can install PrismDB via npm:

npm install prismdb

Once installed, you can import PrismDB into your project:

const PrismDB = require('prismdb');
const db = new PrismDB('database.pris');

Features

  • Simple API: Easily perform CRUD operations.
  • Table-like Structures: Organize your data into tables.
  • Persistence: Data is saved and loaded from .pris files.
  • Lightweight: Minimal setup for small projects and prototyping.

Getting Started

Creating a Table

Create a new table to store your data:

db.createTable('users');

Inserting Data

Insert data into the 'users' table:

db.insert('users', 'user1', { name: 'Alice', age: 30 });

Selecting Data

Retrieve data from the 'users' table:

const user = db.select('users', 'user1');
console.log(user); // Output: { name: 'Alice', age: 30 }

Updating Data

Update existing data in the 'users' table:

    db.update('users', 'user1', { name: 'Alice', age: 31 });

Deleting Data

Delete data from the 'users' table:

db.delete('users', 'user1');

Dropping a Table

If no longer needed, drop a table:

db.dropTable('users');

Contact

Twitter

Discord Server

About

PrismDB is a simple JavaScript key-value store library that provides basic CRUD operations, table-like structures, and saves data to a file.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published