Repository navigation
feat(docs): look up the API by name with appkit docs NAME... - #727
Merged
Merged
Conversation
Contributor
📦 Bundle size reportCompared against
|
| dist | raw | gzip |
|---|---|---|
| JS (runtime) | 1.3 MB | 478 KB |
| Type declarations | 470 KB | 169 KB |
| Source maps | 2.6 MB | 888 KB |
| Other | 11 KB | 3.7 KB |
| Total | 4.4 MB | 1.5 MB |
Per-entry composition (own code — deps external (as shipped))
| Entry | Initial (gz) | Lazy (gz) | Total (gz) | node_modules (min) | Own code (min) |
|---|---|---|---|---|---|
. |
107 KB | 2.5 KB | 110 KB | external | 347 KB |
./beta |
113 KB | 485 B | 114 KB | external | 338 KB |
./testing |
46 KB | 33 KB | 79 KB | external | 229 KB |
./tsdown |
520 B | 0 B | 520 B | external | 813 B |
./type-generator |
26 KB | 0 B | 26 KB | external | 74 KB |
Chunks:
| Entry | Chunk | Load | Size (gz) |
|---|---|---|---|
. |
index.js |
initial | 103 KB |
. |
utils.js |
initial | 4.6 KB |
. |
remote-tunnel-manager.js |
lazy | 2.5 KB |
./beta |
beta.js |
initial | 93 KB |
./beta |
modular.js |
initial | 6.0 KB |
./beta |
stream-manager.js |
initial | 5.9 KB |
./beta |
service-context.js |
initial | 4.3 KB |
./beta |
databricks.js |
initial | 3.3 KB |
./beta |
client.js |
initial | 648 B |
./beta |
index.js |
initial | 20 B |
./beta |
supervisor-api.js |
lazy | 193 B |
./beta |
databricks.js |
lazy | 178 B |
./beta |
index.js |
lazy | 114 B |
./testing |
manifest.js |
initial | 33 KB |
./testing |
index.js |
initial | 10 KB |
./testing |
wide-event-emitter.js |
initial | 2.9 KB |
./testing |
index.js |
lazy | 29 KB |
./testing |
remote-tunnel-manager.js |
lazy | 2.5 KB |
./testing |
utils.js |
lazy | 1.8 KB |
./tsdown |
index.js |
initial | 520 B |
./type-generator |
index.js |
initial | 26 KB |
@databricks/appkit-ui
npm tarball (packed): 406 KB (+1.1 KB) — gzipped download (dist + bin; excludes release-only docs/NOTICE).
| dist | raw | gzip |
|---|---|---|
| JS (runtime) | 436 KB (+508 B) | 150 KB (+281 B) |
| Type declarations | 271 KB (+977 B) | 100 KB (+460 B) |
| Source maps | 862 KB (+1.0 KB) | 291 KB (+472 B) |
| CSS | 16 KB | 3.2 KB |
| Total | 1.5 MB (+2.5 KB) | 544 KB (+1.2 KB) |
Per-entry composition (consumer bundle — deps bundled, peerDeps external)
| Entry | Initial (gz) | Lazy (gz) | Total (gz) | node_modules (min) | Own code (min) |
|---|---|---|---|---|---|
./js |
5.3 KB | 49 KB | 55 KB | 208 KB | 14 KB |
./js/beta |
2.1 KB | 0 B | 2.1 KB | 0 B | 5.0 KB |
./react |
440 KB | 49 KB | 489 KB | 1.4 MB | 178 KB |
./react/beta |
14 KB | 0 B | 14 KB | 25 KB | 16 KB |
Chunks:
| Entry | Chunk | Load | Size (gz) |
|---|---|---|---|
./js |
index.js |
initial | 5.2 KB |
./js |
chunk |
initial | 120 B |
./js |
apache-arrow |
lazy | 49 KB |
./js/beta |
beta.js |
initial | 2.1 KB |
./react |
index.js |
initial | 438 KB |
./react |
tslib |
initial | 2.1 KB |
./react |
apache-arrow |
lazy | 49 KB |
./react/beta |
beta.js |
initial | 14 KB |
Contributor
🤖 AppKit PR bot🔬 Run evalsStart an eval for this PR from the evals-monitor app: Go to Evals Monitor → 📦 Try this PR's app templateScaffolds a new app from this PR's SDK build. Run it in any folder (requires the GitHub CLI — gh run download 43041592607 -R databricks/appkit -n appkit-template-0.93.0-pr.58ce45a-feat-appkit-docs-name-lookup-727 -D appkit-pr-727 \
&& unzip -o "appkit-pr-727/appkit-template-0.93.0-pr.58ce45a-feat-appkit-docs-name-lookup-727.zip" -d "appkit-pr-727" \
&& databricks apps init --template "appkit-pr-727"The template pins |
MarioCadenas
approved these changes
Nov 11, 2026
Agents writing AppKit apps need a component's props before they write code, but `appkit docs` only navigated sections and file paths: `appkit docs BarChart` answered "No section matching", so agents probed `node_modules` and `.d.ts` files instead. `appkit docs BarChart DataTable Select useAnalyticsQuery sql` now prints each name's page, part, hook section or reference page, with props one per line and no table chrome. A multi-name lookup leaves out examples and prints a prop or note that an earlier name already showed only by name, so a screen's worth of names stays short (about 9K characters for ten). An unknown name gets similar names, by name and by component description (DatePicker suggests Calendar). Some behavior was documented only in code, so agents learned it by breaking apps. The docs now state DataTable's column keys and cell formatting, which colors ECharts can draw, the `valueFormatter` signature, the chart `data` row type, and `useMemo` for `useAnalyticsQuery` parameters. Signed-off-by: Pedro Figueiredo <pedro.figueiredo@databricks.com>
Each documented name is classified once, as a component page, a reference page or
a guide, and each file is read once with every line marked as code or not. The
docs layout used to be matched in four places, and code fences were tracked in
three (not at all while indexing).
This fixes lookups that misread the layout:
- `appkit docs Plugin` printed one `void` for five Returns sections: repeated
lines are now only collapsed on component pages, where the generator repeats a
page's intro and the charts share notes.
- `appkit docs Sidebar` answered with styling.md's color section: only
`api/appkit-ui/<group>/<Name>.md` files are component pages.
- A single unknown name (`appkit docs DatePicker`) went to the section index and
never got suggestions; it now gets them, and lists the sections and exits 1
when no name was found.
- A `#` line in a code block ended a section.
A later name refers back to repeated prose ("(as in BarChart)") as it already
did for props, replacing a 100-character threshold. The generator escapes all
props-table cells in one place and notes that `appkit docs` parses the table.
Signed-off-by: Pedro Figueiredo <pedro.figueiredo@databricks.com>
pffigueiredo
force-pushed
the
feat/appkit-docs-name-lookup
branch
from
November 11, 2026 14:45
fe9ded0 to
3912bbd
Compare
pffigueiredo
enabled auto-merge (squash)
November 11, 2026 14:54
MarioCadenas
disabled auto-merge
November 11, 2026 16:52
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
appkit docsnow answers by API name:appkit docs BarChart DataTable Select useAnalyticsQuery sqlprints the props, types and defaults of each name from the installed package's docs, so an agent can look up a whole screen's API in one call instead of probingnode_modulesand.d.tsfiles. Before this,appkit docs BarChartansweredNo section matching "BarChart".What a lookup prints
SelectItem), theappkitreference pages (sql,createApp), and hooks documented in the guides (useAnalyticsQuery).- queryKey, … : as in BarChart,(as in BarChart)), which keeps eight names under 10K characters. Agent harnesses commonly truncate tool output around 10K.appkit docs DatePickersuggestsCalendar). When nothing was found, it also lists the sections and exits 1../docs/...paths behave as before. A single argument is a section query when it matches a section and isn't all documented names.Behavior that was only in the code
Agents learned these by breaking apps, so they are now in the generated pages:
DataTable: which first-row keys become columns, and that every numeric-looking cell (numeric strings included) is formatted as USD or abbreviated, so ids, zip codes and years belong in aTable.colorsand the--chart-cat-*variables must be hex,rgb()orhsl(): ECharts can't resolvevar()or parseoklch()and draws them gray.valueFormattersignature, written out instead of namingChartValueFormatter.useAnalyticsQuery's own section now says to wrapparametersinuseMemo, which was only in the separate Memoization section.Each fact sits in the first sentence of its prop description, because multi-name lookups print only that sentence. The props generator now also escapes
|in prop descriptions, which would otherwise split the table cell.Testing
docs.test.tscovers indexing, single and multi-name output, deduplication and suggestions against a fixture docs tree.generate:types(no drift),check,typecheck,knipandpnpm testlocally. The one failure,typecheck-vite-plugin.test.ts, passes when run on its own and doesn't touch this code.appkit docs NAME...as its only API source. Every app typechecked and built, and the agents found what they needed in one or two lookups.