TL-M0-10 · Create packages/db-types
Why: The generated database types live in this package and nothing else (D22); apps import them as @opleet/db-types. The Backend Engineer's pack E replaces the placeholder with the first generated types.
ID TL-M0-10 · Level L0 · Run order row 10
@opleet/db-types exists with a placeholder type and typechecks.
Before
Section titled “Before”TL-M0-09 is Done.
1 · Create the package
Section titled “1 · Create the package”mkdir -p packages/db-types/srccat > packages/db-types/package.json <<'EOF'{ "name": "@opleet/db-types", "version": "0.0.0", "private": true, "type": "module", "exports": { ".": "./src/database.ts" }, "scripts": { "typecheck": "tsc --noEmit" }}EOFcat > packages/db-types/tsconfig.json <<'EOF'{ "extends": "../../tsconfig.base.json", "include": ["src"]}EOFcat > packages/db-types/src/database.ts <<'EOF'// Placeholder until the first `pnpm db:types` writes the generated types here (D4, D22).export type Database = Record<string, never>;EOF2 · Add TypeScript (the root's version) and typecheck the workspace
Section titled “2 · Add TypeScript (the root's version) and typecheck the workspace”pnpm --filter @opleet/db-types add -D -E typescript@7.0.2pnpm typecheck3 · Commit
Section titled “3 · Commit”git add -Agit commit -m "build(db-types): add the package shell"Expect
Section titled “Expect”- Block 2 ends with “Tasks: 2 successful, 2 total” (web and db-types).
- Block 3: the commit line.
pnpm ls -r --depth -1Four entries: opleet, docs, web and @opleet/db-types.
If it fails
Section titled “If it fails”typecheck fails in db-types: paste the output.
rm -rf packages/db-typesgit checkout -- pnpm-lock.yamlpnpm installDone 2026-10-05 (zuki)