dal/dal/Binding.ts

12 lines
329 B
TypeScript
Raw Normal View History

2024-08-21 01:28:40 +00:00
import { createRequire } from "node:module";
const require = createRequire(import.meta.url);
type RowIterator = {
next: () => Buffer;
free: () => void;
};
2024-08-21 01:28:40 +00:00
type SQLite = {
InitSQLite: (pragmas: Buffer) => void;
RowIterator: (input: Buffer) => RowIterator;
2024-08-21 01:28:40 +00:00
};
export default require("../build/Release/dal.node") as SQLite;