dal/client/Binding.ts

12 lines
332 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;
2024-08-29 20:39:27 +00:00
cleanup: () => void;
};
2024-08-21 01:28:40 +00:00
type SQLite = {
2024-08-29 20:13:48 +00:00
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;