Commit d21d74e
authored
docs(apps): codegen quality guidelines — AppKit API, type casts, version pinning (LKB-12428, LKB-12465, LKB-12614) (#69)
## Summary
Three codegen-quality guidelines for the `databricks-apps` skill, each
addressing a distinct regression observed in apps-mcp-evals nightlies:
1. **AppKit API surface** (LKB-12465): run `npx @databricks/appkit docs
<section>` before writing server code. Training data has stale shapes; a
single invented signature fails `tsc --noEmit`.
2. **TypeScript casts** (LKB-12428): never use `as unknown as <T>` —
`appkit lint` enforces `no-double-type-assertion`. Use Zod, type guards,
or mapper functions.
3. **AppKit version pinning** (LKB-12614): never override
`@databricks/appkit` version in `package.json` — `databricks apps init`
sets the correct version. Agent was writing stale versions from training
data (0.11.0 when latest is 0.31.0).
Plus: smoke-test selector guidance (use Playwright locator APIs, not
React Testing Library), data-size cap for analytics payloads.
Supersedes PR #65 (which covered only the TypeScript-casts bullet).
Mario Cadenas's review feedback from #65 is incorporated (auto-gen
queryKey files carve-out, warehouse-unavailable `unknown` case).
## Documentation safety checklist
- [x] Examples use least-privilege permissions
- [x] Elevated permissions explicitly called out where required
- [x] Sensitive values are obfuscated
- [x] No insecure patterns introduced
Co-authored-by: Isaac1 parent 8d44124 commit d21d74e
1 file changed
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| 41 | + | |
41 | 42 | | |
42 | 43 | | |
43 | 44 | | |
| |||
0 commit comments