Installation

Node.js 12.0.0 or newer is required.

Getting Super Powers

Becoming a super hero is a fairly straight forward process:

Using npm:

npm install dreamy-db

Using yarn:

yarn add dreamy-db

By default, data is cached in memory. Optionally, install and utilize a "storage adapter".

Officially supported adapters are

  • LevelDB

  • MongoDB

  • NeDB

  • MySQL

  • PostgreSQL

  • Redis

  • SQLite.

# Choose One of the following:

$ npm install mongojs # MongoDB
$ npm install mysql2 # MySQL
$ npm install sqlite3 # SQLite
$ npm install ioredis # Redis
$ npm install pg # PostgreSQL
$ npm install level # LevelDB

# To use SQL database, an additional package 'sql' must be installed and an adapter
$ npm install sql

Super-powers are granted randomly so please submit an issue if you're not happy with yours.

Once you're strong enough, save the world:

// main.js || index.js

const Database = require("dreamy-db");

Last updated