BetterSqlite3
According to their official docs (opens in a new tab), BetterSqlite3 is the fastest and simplest library for SQLite3 in Node.js.
Drizzle ORM embraces SQL dialects and dialect specific drivers and syntax and unlike any other ORM,
for synchronous drivers like better-sqlite3
we have a sync API and we mirror most popular
SQLite-like all
, get
, values
and run
query methods syntaxs.
npm install drizzle-orm better-sqlite3
npm install -D drizzle-kit
import { drizzle, BetterSQLite3Database } from 'drizzle-orm/better-sqlite3';
import Database from 'better-sqlite3';
const sqlite = new Database('sqlite.db');
const db: BetterSQLite3Database = drizzle(sqlite);
const result = db.select().from(users).all()