Document typedefs better. Fix tables deletion schema sync issue.

This commit is contained in:
2026-04-05 09:03:47 +01:00
parent 01b96d788e
commit 259a684136
14 changed files with 869 additions and 104 deletions
+10 -2
View File
@@ -1,3 +1,11 @@
export default function grabDirNames(): {
ROOT_DIR: string;
import type { BunSQLiteConfig } from "../types";
type Params = {
config?: BunSQLiteConfig;
};
export default function grabDirNames(params?: Params): {
ROOT_DIR: string;
BUN_SQLITE_DIR: string;
BUN_SQLITE_TEMP_DIR: string;
BUN_SQLITE_LIVE_SCHEMA: string;
};
export {};
+7 -1
View File
@@ -1,7 +1,13 @@
import path from "path";
export default function grabDirNames() {
export default function grabDirNames(params) {
const ROOT_DIR = process.cwd();
const BUN_SQLITE_DIR = path.join(ROOT_DIR, ".bun-sqlite");
const BUN_SQLITE_TEMP_DIR = path.join(BUN_SQLITE_DIR, ".tmp");
const BUN_SQLITE_LIVE_SCHEMA = path.join(BUN_SQLITE_DIR, "live-schema.json");
return {
ROOT_DIR,
BUN_SQLITE_DIR,
BUN_SQLITE_TEMP_DIR,
BUN_SQLITE_LIVE_SCHEMA,
};
}