0.22.9 • Published 4 years ago
@ladc/sqlite3-adapter v0.22.9
@ladc/sqlite3-adapter
LADC is a common API on top of relational database (SQL) connectors. It can connect to Postgresql, MariaDB / MySQL, SQLite. The API is inspired from PDO and JDBC. It’s named LADC for “a Layer Above Database Connectors”.
This package is a plugin for LADC. It is an adapter for SQLite, using the connector sqlite3 (SQLite).
Install
npm install @ladc/sqlite3-adapter ladc
Usage
How to create a connection:
import ladc from "ladc";
import sqlite3Adapter from "@ladc/sqlite3-adapter";
const cn = ladc({
adapter: sqlite3Adapter({ fileName: `${__dirname}/mydb.sqlite` }),
initConnection: async (cn) => {
await cn.exec("PRAGMA foreign_keys = ON");
},
});
Contribute
With VS Code, our recommanded plugin is:
- TSLint from Microsoft (
ms-vscode.vscode-typescript-tslint-plugin
)
0.22.9
4 years ago
0.22.8
4 years ago
0.22.7
4 years ago
0.22.6
4 years ago
0.22.5
4 years ago
0.22.4
5 years ago
0.22.3
5 years ago
0.22.2
5 years ago
0.22.0
5 years ago
0.21.0
5 years ago
0.20.1
5 years ago
0.20.0
5 years ago
0.19.1
6 years ago
0.19.0
6 years ago
0.5.2
6 years ago
0.5.1
6 years ago
0.5.0
6 years ago
0.4.1
6 years ago
0.4.0
6 years ago