Add a per-version compatibility page to the API reference - #70
Merged
Merged
Conversation
The Titanium API entry pages gained a "Compatibility" link beside "Release notes", pointing at /docs/sdk/<version>/compatibility: what that one release needs from your machine, and what it builds for. /docs/reference/compatibility (TI-75) already generated this data, but across every release at once. That is the right shape for "when did Java 17 become the floor" and the wrong one for a reader already standing on /docs/sdk/13.4.0, who has picked a release and wants its column. Until now the reference linked to the compatibility data not at all. tidev/titanium-docs#269 is the argument for generating it rather than writing it: that PR hand-patched the legacy matrix to say Android API 36 for 13.4.0+, a fact registry/sdk/13.4.0/toolchain.json already recorded. Every number the old matrix carries by hand is captured per release by scripts/capture-toolchain.ts. Nothing here restates a range. compat.ts turns one toolchain.json into rows, and minimumCli decides the CLI floor for this page and the cross-release one alike; the generated partials are byte-identical. Ranges are printed as the SDK declares them, which is the string `ti info` prints beside "Supported:". Three sections rather than one table: the old matrix ran Node, Java, Xcode and the Android SDK down a single column, which reads as one checklist when it is really three - a Linux reader has no Xcode to compare against. Java leads the Android section rather than trailing it, where the SDK's own package.json order would put it. A vendor key this repository has never heard of still gets a row, since the key set is the SDK's to change. All 20 compiled versions carry a capture, main included, so the pages are prerendered with dynamicParams off and the link is unconditional where the release-notes link is gated. Older versions are served but not indexed, on the same reasoning as the reference itself: twenty near-identical tables are twenty ways to land on the wrong one. TI-94 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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.
Adds a Compatibility link beside "Release notes" on every Titanium API entry page (
/docs/sdk,/docs/sdk/13.4.0, ...), pointing at a generated/docs/sdk/<version>/compatibility.Closes TI-94.
Why
/docs/reference/compatibility(TI-75) already generates this data, but across every release at once. That is the right shape for "when did Java 17 become the floor" and the wrong one for a reader already standing on/docs/sdk/13.4.0— they picked a release and want its column. Until now the reference linked to the compatibility data not at all.tidev/titanium-docs#269 is the argument for generating it rather than writing it: that PR hand-patched the legacy matrix to say Android API 36 for 13.4.0+, a fact
registry/sdk/13.4.0/toolchain.jsonalready recorded. Every number the old matrix carries by hand is captured per release byscripts/capture-toolchain.ts.What the page shows
Per release, read out of its own
toolchain.json:Ranges are printed as the SDK declares them, which is the string
ti infoprints beside "Supported:".ti infois offered at the top of the page, ahead of the tables: it reads the same declarations and reports them against the machine the reader is actually sitting at.Notes on the shape
compat.tsturns onetoolchain.jsoninto rows, andminimumClidecides the CLI floor for this page and the cross-release one alike. The generated partials are byte-identical (pnpm docs:compat:checkpasses untouched).package.jsonauthoring order would put it.ToolchainSchemakeepsvendorloose because the key set is the SDK's to change; a release adding a component appears rather than vanishing until someone edits a list.mainincluded, so the pages prerender withdynamicParams = falseand the link is unconditional where the release-notes link is gated.isIndexedVersion): twenty near-identical tables are twenty ways to land on the wrong one. The sitemap lists only the indexed set, so it cannot contradict the page's ownnoindex.Wiring
links.tsresolves the new segment (so a post or guide linking to it is checked rather than reported dead),sitemap.tslists the indexed ones, andia.test.tsnow holds bothrelease-notesandcompatibilityreserved against type names.Checks
pnpm check,pnpm lint,pnpm test(638 pass),pnpm check:docs,pnpm check:em-dash,pnpm docs:compat:checkall pass. Pages verified rendering at 13.4.1, 13.4.0, 12.5.0 andmain; uncaptured versions 404.🤖 Generated with Claude Code