Uh oh!
There was an error while loading. Please reload this page.
docs(guides,tooling): clear four .md pages off the doc-snippet ledger (#5174 batch 2) - #5967
Merged
Merged
Conversation
…#5174 batch 2) Walks `content/docs/guide/plugins.md`, `content/docs/guide/building-crud-app.md`, `content/docs/rfcs/0001-clipboard-paste.md` and `content/docs/guide/architecture.md` off `UNGATED_DOCS` — 89 diagnostics, ledger 53 -> 49 entries, covered documents 169 -> 173. Each page reached zero the two honest ways only: a block that should compile made self-contained against the built `dist/` (8 blocks now compile, 4 of them after an edit), or a `FRAGMENT_MARKER` with a written measured reason for one that genuinely cannot (34 blocks). Nothing about the gate's strictness moved — the whole mechanism half of the script is byte-identical to `main`. Three real documented-API defects surfaced and were fixed rather than declared: `building-crud-app`'s REST adapter passed `QueryParams['$orderby']` (a four-shape union) straight into `URLSearchParams.set`, which takes a string; its `TaskDetail` component used `SchemaRenderer` with no import of its own; and `architecture`'s "Type Safety" section, marked `// ✅ Type-checked`, set `ButtonSchema.onClick` to the string `'handleClick'` where the declared type is `() => void | Promise<void>`. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019b5UBNMtTzKbVtZZGvFuxe
yinlianghui-tw
marked this pull request as ready for review
August 24, 2026 09:42
Uh oh!
There was an error while loading. Please reload this page.
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 freeto 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.
Part of #5174 — batch 2. The card stays open: 5
.mdguide entries remain after this.What this does
Walks four pages off
UNGATED_DOCSinscripts/check-doc-snippet-types.mjs, clearing the 89 diagnostics they were carrying.content/docs/guide/plugins.mdcontent/docs/guide/building-crud-app.mdcontent/docs/rfcs/0001-clipboard-paste.mdcontent/docs/guide/architecture.mdLedger entries 53 → 49. Covered documents 169 → 173. 42 blocks newly under the gate.
Every page reached zero the two honest routes only — a block that should compile made self-contained against the built
dist/, or aFRAGMENT_MARKERwith a written measured reason for one that genuinely cannot. There is no third route in this diff.Three real documented-API defects the ledger was hiding
These are why covering
guide/architectureandbuilding-crud-appwas worth doing rather than declaring them wholesale:building-crud-app.md— the guide'sRestDataSourcepassedQueryParams['$orderby']straight intoURLSearchParams.set.$orderbyis a four-shape union (an OData clause string · aRecordmapping field name to'asc'/'desc'·string[]· an array of sort objects) andsettakes a string (TS2345). Narrowed to the string form with a comment saying why, rather than stringifying a shape the server cannot parse.building-crud-app.md— theTaskDetailcomponent usedSchemaRendererwith no import of its own. A reader copying that block gotTS2304.architecture.md— the section titled Type Safety, with the line marked// ✅ Type-checked, setButtonSchema.onClickto the string'handleClick'. The declared type is a zero-argument function returningvoidor a promise of it (TS2322). The block now declares a handler and passes it.The fourth edited block is
architecture.md's step-2 renderer example, which referenced aschemadefined only in the step-1jsonfence; it now carries that schema as a typedBaseSchemaconstant, so the block is copy-pasteable.The pages that are mostly fragments are mostly fragments for a stated reason:
guide/pluginsand the clipboard-paste RFC document a package the reader is being taught to create, and an RFC's signature excerpts have no bodies by design. Every marker names which of those it is.The four binding invariants, measured
Diffed programmatically between
origin/main's copy of the script and this branch's copy:ADDED ledger entries: []— andpreviously-covered docs that are now UNGATED: []surviving entries with a non-measured reason: [](49 checked)REMOVED entries:is exactly the four pages named above and nothing else.Strictness proven byte-for-byte, not argued. Everything from the
// ── Fence scanningbanner to EOF —scanFences,listDocuments,derivePackageTypePaths,analyze,compileSnippets, the reporting andmain— is byte-identical toorigin/main(475 lines).DOC_EXTENSIONS,TS_FENCE_LANGUAGES,FRAGMENT_MARKER,MIN_REASON_LENGTHandCOMPILER_OPTIONSeach hash identical. The entire script diff is the four removed ledger entries plus the ledger's own docblock prose: 27 insertions, 34 deletions.CI cost under the #4846 ruling — stated, not absorbed
--build-filtergrew 19 → 20 filters (@object-ui/plugin-dashboard, pulled in by exactly one line:guide/plugins.md'simport '@object-ui/plugin-dashboard').Turbo build tasks stayed 33 → 33, and the two task sets are identical package-by-package from
--dry=json(tasks ADDED: [],tasks REMOVED: []) — the new filter was already in the closure as a transitive dependency. Four more covered pages cost this gate zero extra build tasks. Nothing here for the maintainer to weigh.(The real
turbo run buildreports 32 where--dry=jsonreports 33: the difference is@object-ui/test-support#build, which the dry run enumerates but which carries no build command. Both sides of the before/after comparison were measured the same way, so the delta of zero is unaffected.)Verification
All at
41addc61a, working tree clean and byte-identical to what is pushed, union re-run after that commit, from the repo root, against a build of the gate's own filter closure (32 tasks, all successful, serialised through the container's shared heavy-verify entry point). Exit codes captured before any pipe; each line quotes the gate's own printed verdict.node scripts/check-doc-snippet-types.mjs→ exit 0.Scanned 222 document(s): 173 covered (37 of them hold a ts/tsx block), 49 ungated·Covered blocks: 203 — 135 to compile, 68 declared fragment(s).·Syntax phase: every block parsed, so every one of them reached the semantic phase.·Semantic phase: 135 of 135 block(s) judged, 0 failed.·Every covered documentation snippet compiles against the built types.Controls green: resolution landed onpackages/types/dist/index.d.ts, sentinel producedTS2305, positive control 0 diagnostics.scripts/__tests__/check-doc-snippet-types.test.ts→Test Files 1 passed (1)/Tests 20 passed (20). Running the script is not running its test; both were run.check-doc-component-types→ exit 0,Every documented component type is registered.(183 doc files, 1056 code blocks)check-doc-links→ exit 0,Links are valid across 13 scan roots.check-control-bytes→ exit 0,OK (scanned 4950 tracked text file(s); skipped 85 binary), plus a manual control-byte grep over all five changed files: no hits.check-lint-coverage→ exit 0,46/46 packages linted, 0 with outstanding errors.lint:rootinvocation) → exit 0,0 errors, 26 warnings, all pre-existing; the one changed.mjsreportserrorCount 0, warningCount 0.pnpm check(the CLI self-check the Lint workflow runs) → exit 0,Analyzing 615 files... ✓ All checks passed.Changeset: none owed, and no label.
node scripts/check-changeset-presence.mjs→ exit 0: "5 file(s) changed, 0 of them under the src/ of a package the release covers … No source of a released package changed in this range, so no changeset is owed." Followed its verdict. ⛔ Noskip-changesetlabel was applied: that label is not a mechanism in this repo — objectui#3724 established it was documented by a since-deleted second workflow inventory and "neither the workflow nor the label was ever real", a factscripts/__tests__/ci-cd-pipeline-doc.test.tsstill pins.check-changeset-no-major→ exit 0.Lint scope, declared. The root eslint task was run whole, not narrowed. Its population is read from eslint's own config via
--format json: 166 files, of which 0 are.md— linting a changed.mddirectly answersFile ignored because no matching configuration was supplied, so four of the five changed files are outside eslint's population by its own configuration. The other 46 per-packagelinttasks are scoped topackages/*/,apps/*/andexamples/*/, which this diff does not touch at all.Fragment markers re-verified rather than inherited.
fumadocs-mdx15.2.3 selects the compiler format by extension (filePath.endsWith(".mdx") ? "mdx" : "md", read from its own dist, two call sites). All four changed.mdfiles were then compiled through@mdx-js/mdx3.1.1 in formatmd: all four compile, anddoc-snippetoccurs 0 times in every compiled output against 34 occurrences in source.Reverse verification — prediction written before each run, direction included
No build artifact sits between the mutation and the thing under test on either leg: the mutation is markdown the gate reads straight from disk, and the
dist/*.d.tsit compiles against is untouched, so no rebuild was needed. Each leg proved the mutation reached disk by grepping the specific text meant to change — never an editor's exit code — and each carried atrap … EXIT INT TERMrestore.Leg 1 — revert
architecture.mdonly, keep its ledger removal. Predicted: exit 1; exactly 25 diagnostics, all on that page; fragments 68 → 58; blocks-to-compile 135 → 145; the two edited blocks fail again asTS2322andTS2304; NOTE printed; direction MORE findings. Observed: exit 1;25, all on that page;Covered blocks: 203 — 145 to compile, 58 declared fragment(s);TS2304: Cannot find name 'schema'and theTS2322ononClick(string not assignable to the handler type); NOTE printed. Match including direction.Leg 2 — revert all four pages, keep all four ledger removals. Predicted: exit 1; exactly 89 diagnostics split 20/21/23/25; fragments 68 → 34; blocks-to-compile 135 → 169; NOTE printed; direction MORE. Observed: exit 1; 89 exactly, split
20 plugins / 21 building-crud-app / 23 clipboard-paste / 25 architecture— matching the baseline to the unit and per page;Covered blocks: 203 — 169 to compile, 34 declared fragment(s);Syntax phase: 7 block(s) failed to parse; NOTE printed. Match including direction.Restore leg run, not skipped:
git statusclean, 34 markers back on disk,git diff HEADempty, gate exit 0 with135 of 135 block(s) judged, 0 failed.Two dispatch measurements checked
building-crud-app's recorded reason over-stated its debt. It recorded20 undefined-name / 4 unresolved-module; measured 14TS2304and 3TS2307. Confirmed exactly. The stale numbers were not copied forward — the entry is deleted, so the drift is retired rather than re-worded.TS2305/TS2724/TS2614across all 89 diagnostics. The getting-started guides teach ~14 symbols the packages do not export — one decision per symbol, applied everywhere (the #5160 class, oncontent/docs/guide/**) #5343 cleared that class completely; every diagnostic here was genuine per-page fragment / self-containment judgement. ⛔ No fabricated symbol was re-decided per page.What is left on this card
5
.mdguide entries:plugin-development25 ·schema-rendering27 ·theming29 ·layout45 ·component-registry59 = 185 diagnostics, plus 12.mdxand 32 READMEs.layoutandcomponent-registryare 104 between them and are a batch of their own, as the batch-1 seat noted.Generated by Claude Code