A node module for creating/managing easy-access SQLite databases.
Install simpledb
via your favorite package manager.
npm install @gavinhsmith/simpledb
yarn add @gavinhsmith/simpledb
TypeDoc Files can be found at the API Docs.
Include in your project create a new instace of the Database class.
// Import the module.
import Database from "@gavinhsmith/simpledb";
// Load the database.
const db = Database("file.db");
// Qeury the database.
db.table("users").allEntries().then((entries) => {...});
Module can be configed in the Database
constructor.
const db = Database("file.db", {
verbose: true,
});
Config Option | Type | Default | Description |
---|---|---|---|
verbose | boolean |
false |
Enables sqlite3.verbose() and enables verbose logging throughout the module. |
Clone the repository, and run npm i
or yarn
to install the dependancies and build the module. Run module tests via the test
script in package.json.
Workflow tests require act. You do not need this for module development, as workflow tests are not run during CI.
I'll review pull requests in time.