@sqb/sqlite
v6.0.12
Published
SQB adapter for Node.js and Bun's native SQLite drivers
Downloads
688
Readme
About SQB
SQB is an extensible, multi-dialect SQL query builder and Database connection wrapper for NodeJS.
About @sqb/sqlite
This package is a SQB Adapter for SQLite that uses the runtime's own native SQLite
bindings instead of a WASM build:
node:sqlitewhen running under Node.js (>= 22.5)bun:sqlitewhen running under Bun
The correct driver is picked automatically at runtime — no configuration needed. If you
need SQLite support on a runtime without a native driver (e.g. older Node versions, or
in the browser), use @sqb/sqljs instead — both adapters share the same
@sqb/sqlite-dialect SQL serialization rules, so queries behave
identically either way.
Installation
$ npm install @sqb/sqlite --saveUsage
import '@sqb/sqlite';
import { SqbClient } from '@sqb/connect';
const client = new SqbClient({
driver: 'sqlite',
database: '/path/to/database.db', // or ':memory:'
});Node Compatibility
- node >= 22.5 (for
node:sqlite), or any recent Bun version (forbun:sqlite)
License
SQB is available under MIT license.
