shoehive/store/sqlite
shoehive/store/sqlite: the SQLite Store adapter (ADR 0009), built on better-sqlite3
(an optional peer dependency: install it next to shoehive).
import { createServer } from 'shoehive/server';import { sqliteStore } from 'shoehive/store/sqlite';
const server = createServer({ games, store: sqliteStore({ file: './shoehive.db' }) });Tables survive a process restart: on startup the server lists the open tables, loads
each snapshot and replays the log after it. Several apps can share one file by giving
each a different tablePrefix.
Interfaces
Section titled “Interfaces”Type Aliases
Section titled “Type Aliases”Functions
Section titled “Functions”References
Section titled “References”SessionRecord
Section titled “SessionRecord”Re-exports SessionRecord
Re-exports Store
StoreConflictError
Section titled “StoreConflictError”Re-exports StoreConflictError
StoredEntry
Section titled “StoredEntry”Re-exports StoredEntry
StoredSnapshot
Section titled “StoredSnapshot”Re-exports StoredSnapshot
