zenstack/packages/dialects/sql.js/test/getting-started/database.ts
Yiming Cao a2aff8160f
feat: add sql.js dialect (#134)
* feat: add sql.js dialect

* update

* update
2025-08-04 17:11:42 +08:00

12 lines
306 B
TypeScript

import type { Database } from './types';
import { Kysely } from 'kysely';
import initSqlJs from 'sql.js';
import { SqlJsDialect } from '../../src';
const SqlJsStatic = await initSqlJs();
export const db = new Kysely<Database>({
dialect: new SqlJsDialect({ sqlJs: new SqlJsStatic.Database() }),
});