preciazo/db-datos/db.js

9 lines
285 B
JavaScript
Raw Normal View History

// @ts-check
import Database from "better-sqlite3";
import { drizzle } from "drizzle-orm/better-sqlite3";
2023-12-30 00:49:32 +00:00
import { DB_PATH } from "./drizzle.config.js";
import * as schema from "./schema.js";
export const sqlite = new Database(DB_PATH);
export const db = drizzle(sqlite, { schema });