Skip to content

docs(ui): describe this repository's frontend and keep its bundle out of local indexes - #305

Merged
sunerpy merged 1 commit into
mainfrom
docs/ui-readme-local-index
Oct 3, 2026
Merged

sunerpy merged 1 commit into
mainfrom
docs/ui-readme-local-index

Conversation

@sunerpy

@sunerpy sunerpy commented Oct 3, 2026

Copy link
Copy Markdown
Owner

Summary

Two documentation follow-ups to the browser viewer (#298, #300).

ui/README.md

The README was imported from upstream and still described upstream's npm monorepo. Wrong here:

  • a root npm run build, build:lib and dist/viewer;
  • the @colbymchenry/codegraph-ui package and its versioning and publishing;
  • scripts/check-ui-*.mjs;
  • engine files under src/.

It now describes this repository:

  • Build. make ui, make ui-check (the CI UI job), npm run check, npm test, and the committed bundle the crate's build.rs embeds. It also says plainly that npm run dev has no API behind it, with the two ways to work against a real index.
  • Adapter. This tree's actual GraphAdapter: 14 required methods including screens, with steps optional and left out of createHttpAdapter. The shapes are those crates/codegraph-ui/src/api/ serialises.
  • Engine and server references point at the Rust code. find_dynamic_boundaries (crates/codegraph-ui/src/api/boundary.rs) runs explore's scan_dynamic_dispatch. The hierarchy walk is build_type_hierarchy. Upstream's countImplementers is not ported. The Rust index synthesizes no dispatch edges.
  • Numbers that direction D moved.
    • Hierarchy rows and indent: 26 and 28 px (HIER_ROW_H, HIER_INDENT).
    • Map layer gap: 44 px.
    • The Routes table gains #/dead and #/steps.
    • "Not live" now shows in the command bar.
  • The rest is upstream's. The design sections (export, entry points, screens, the end cap, live updates) keep upstream's text.

docs/upstream-sync/UPSTREAM.md gains a dated entry recording the rewrite as a local layer. Existing entries are byte-identical.

AGENTS.md

A short note in "Navigate with CodeGraph first" shows the local .codegraph/config.toml that keeps the committed, minified bundle out of an index of this repository. Measured on an archive of main:

  • the bundle adds 3,288 symbols, 89 % of them with one- or two-letter names;
  • it puts six of them into the top eight of the viewer's most-depended-on list;
  • it heads the entry-point files with 651 top-level calls.

With the exclusion, both lists are real code.

Verification

  • make fmt-check and make docs-check pass (/tmp/evidence-tidy/docs-checks.log).
  • Every relative link in ui/README.md resolves.
  • The README's claims were checked against this tree:
    • the router's views;
    • adapter.ts's interface;
    • hierarchy-model.ts, map-model.ts and screens-model.ts constants;
    • TopBar.svelte's "Not live";
    • the /api/trails readOnly field;
    • the hierarchy suite's note that countImplementers is not ported.
  • No code changes, and ui/README.md is not part of the build.

🤖 Generated with Claude Code

… of local indexes

ui/README.md still described upstream's npm monorepo: a root `npm run build`,
the `@colbymchenry/codegraph-ui` package and its publishing, and engine files
under `src/`. It now covers `make ui` and `make ui-check`, the committed bundle
the crate embeds, the Rust files behind the server and the engine, and what the
Rust server does not send yet. The design sections keep upstream's text with
paths, numbers and claims checked against this tree: the hierarchy's 26/28 px
rows and indent, the Map's 44 px layer gap, the 14 required adapter methods,
the `#/dead` and `#/steps` routes. UPSTREAM.md records the rewrite as a local
layer.

AGENTS.md now shows the local `.codegraph/config.toml` that keeps the minified
bundle out of an index of this repository, where it adds about 3,300 symbols
and pushes six of them into the top eight most-depended-on list.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5ddb5baf97

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread AGENTS.md
Comment on lines +38 to +39
`make ui` output. Indexed, it adds about 3,300 symbols, nine in ten of them with
one- or two-letter names, that crowd the most-depended-on and entry-point lists,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Derive the viewer counts instead of freezing them

Whenever make ui rebuilds the minified bundle, both the symbol count and short-name ratio can change, but no source-contract test or documentation check derives or verifies these values—the only repository occurrence is this prose. Consequently the canonical contributor guide can silently retain obsolete evidence; either omit the numeric claims or derive and pin them in scripts/docs-check.py or a product test.

AGENTS.md reference: AGENTS.md:L134-L136

Useful? React with 👍 / 👎.

@codecov

codecov Bot commented Oct 3, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #305   +/-   ##
=======================================
  Coverage   95.05%   95.05%           
=======================================
  Files         197      197           
  Lines      108387   108387           
=======================================
+ Hits       103023   103025    +2     
+ Misses       5364     5362    -2     

see 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@sunerpy
sunerpy merged commit 94b555c into main Oct 3, 2026
11 checks passed
@sunerpy
sunerpy deleted the docs/ui-readme-local-index branch October 3, 2026 03:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant