npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

viperdb

v0.0.5

Published

A simple data base in javascript

Readme

Viper data base

This Module makes it possible to store data on the user's pc.

Installation

npm install viperdb --save

How to use

Create data

DataBases

In viperdb we organize our data into tables and tables in databases, the following example shows how to create a database.

const viper = require("viperdb");

//             Database path   Database name
viper.NewDataBase('./storage', 'appconfig'); 

table

Tables are essential for data storage, to create a table you need to create a database first. Example of creating a table:


const viper = require("viperdb");

viper.NewDataBase('./storage', 'appconfig');
//         Database path   Database name  table name
viper.NewTable('./storage', 'appconfig', 'userprefs');

Data

We can store data in tables, so to store new data we need a table. Example of how to save data:


const viper = require("viperdb");

viper.NewDataBase('./storage', 'appconfig');

viper.NewTable('./storage', 'appconfig', 'userprefs');
//         Database path   Database name  table name      data
viper.AddData('./storage', 'appconfig', 'userprefs', '{name:shadow}');

Note: you can only store data in JSON format inside a string!

    viper.AddData('databasepath', 'databasename', 'tablename','{dataname:datavalue}');

Get data

Taking data on a table

To get data from a table, you need to specify the database path, the database name, the name of the table where the data is located, and the name of the data.

    viper.GetData('./storage', 'appconfig', 'userprefs', 'name');

The return will be a string containing the data.

shadow

Taking a table from a database

It is also possible to receive data from a table with the "GetTable()" function

    viper.getTable('./storage', 'appconfig', 'userprefs');

The return will be a string containing all the data stored in that table.

{name:shadow}

Remove Data

In the same way that we can create databases and tables, it is also possible to delete them

Delete Data

To remove data from a table, we use the "RemoveData()" function

    viper.RemoveData('./storage', 'appconfig', 'userprefs', 'name');

Delete Table

Using the "RemoveTable()" method we can delete a table at once.

    viper.RemoveTable('./storage', 'appconfig', 'userprefs');

Be careful, keep in mind that by deleting a table, you will be losing all the data that was stored in it!

Delete DataBase

If you want to delete the database at once, you can use the "RemoveDataBase()" method, but keep in mind that it will be lost forever.

    viper.RemoveDataBase('./storage','appconfig');

File Exist

The "FILEExist()" module returns a boolean, with it you can know if you have already created a database file.


    var init = viper.FileExist('./storage','appconfig');

    init ? ... : ...

Update Data

With the "DataUpdate()" module you can update the value of a data.

//                   dbpath /  dbname / table name/ data name / inner value;                             
    viper.DataUpdate('./local','gameconfig','userdata','name','soul')