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 🙏

© 2024 – Pkg Stats / Ryan Hefner

fortydb

v0.0.2

Published

A simple local database

Downloads

7

Readme

FortyDB (BETA)

A simple database for small projects or blogs. This database is completely local and is in beta phase.

Version 0.0.2

Functions

  1. Starting Services
  2. Get Data
    1. General Data
    2. Specifies
    3. Base Data
  3. Set Data
    1. Simple Data
    2. Base Data
    3. File (Coming Soon)
    4. From Server (Coming Soon)
  4. Server (Coming Soon)
  5. User Service
  6. Settings
  7. Notes

1. Starting Services

Installing FortyDB on your project:

npm install fortydb

Once fortydb is installed in your project, call our services

// ADMINISTRATOR OF DATABASE
const {Admin} = require('fortydb');

// DEFAULT SETTINGS VARIABLE
const database = new Admin();

// VARIABLE OF DATA FROM DATABASE
let data = database.start(); // THIS RETURN JSON OBJECT

console.log(data)



// OUTPUT
{
	date: "Date",
	data: {
		simple: {},
		base: [],
		code: "ASdjsakdfjaksjdljqi12983912",
		files: {
			data: [],
			locals: false
		}
	}
}

Get Data

For get data is very simple

// GET ALL DATA
let all_data = database.start();

// GET SPECIFIES DAT
let specificies_data = database.getData('name_of_data');

// GET BASE DATA
let base_data = database.getBase(0) // NUMBER OR POSITION OF DATA 

Set Data

You can save any information such as: Strings, Objects, Arrays

// SET DATA IN THE DATABASE
database.setData('name_of_data', 'data');

// SET BASE DATA IN THE DATABASE
database.setBase('data');

User Service

Users as such do not exist, but it is the way to connect directly to the database, if you forget the password or the user will lose all their information.

The user consists of a username and a password, in the end only with these two can open the database, each database depends only on these 2, there is no security code or any other service.

// ADMINISTRATOR OF DATABASE
const {Admin} = require('fortydb');

// VARIABLE LOGIN
const database = new Admin({
	user: {
		user: "FortyDB",
		password: "Example123"
	}
});

Settings

// ADMINISTRATOR OF DATABASE
{
	route: "./routeDatabaseFolder",
	user: {
		user: "admin",
		password: "admin"
	}
	name: "name_of_database.fdb"
};

Notes

  • The database is in beta phase therefore it only has basic functions. We are currently at version 0.0.1

  • The database is not recommended to be used for large or highly confidential projects since the database does not have good security. But it is fully functional if the case is that you want to save info for your application or blog. Or simply for a web app where there is a login and user registration.

  • For greater stability and speed, an advanced mode will be added in which each data has a very specific space on the disk