Repository navigation
docs(feature-map): keep the page's sources in the repo; npm run docs:feature-map - #567
Merged
Merged
Conversation
…m run docs:feature-map docs/feature-map.html was built from a template, an inventory file and a script that lived only in one session's scratch folder, so the next change meant hand-editing the generated page. The sources now live in docs/feature-map/ (template.html, data.js, app.js), and scripts/feature-map/build.mjs fills in the diagrams from FEATURE_MAP.md and writes the page. `--board <file>` also writes the planning-board page that is published as an Artifact. The build reproduces today's docs/feature-map.html byte for byte. Tests cover diagram placement and escaping, a `$` in the sources staying literal, a missing diagram failing the build, and the static wrapper (A/B: two fail with plain-string replacement and no range check). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: 58ca45c0-b3d9-4b60-9c97-0610470cc0cd) |
| }; | ||
|
|
||
| // Routes per feature, from the 153 pinned in http-contract.test.ts. | ||
| const ROUTES = [ |
| ]; | ||
|
|
||
| // Unit-test files per package. | ||
| const TESTS = [ |
| ['packages/workflow-contract', 1], ['packages/ui-shared', 1], | ||
| ]; | ||
|
|
||
| const E2E_GROUPS = ['PostgreSQL', 'MySQL', 'MariaDB', 'SQL Server', 'Oracle', 'DB2', 'SQLite', 'Azure SQL', 'ClickHouse', 'Redshift', 'CockroachDB', 'YugabyteDB', 'TiDB', 'DuckDB', 'Smoke', 'Sign-in', 'One admin or several', 'Workspaces', 'SQL Editor (14 specs)', 'Send feedback', 'Browse', 'History', 'Revert', 'Revert edges', 'Access SQLite', 'Workflow', 'Utilities', 'DB Access', 'Access all', 'Migrations in Git', 'Execute gate', 'Backup & Restore', 'Backup commands']; |
| const E2E_GROUPS = ['PostgreSQL', 'MySQL', 'MariaDB', 'SQL Server', 'Oracle', 'DB2', 'SQLite', 'Azure SQL', 'ClickHouse', 'Redshift', 'CockroachDB', 'YugabyteDB', 'TiDB', 'DuckDB', 'Smoke', 'Sign-in', 'One admin or several', 'Workspaces', 'SQL Editor (14 specs)', 'Send feedback', 'Browse', 'History', 'Revert', 'Revert edges', 'Access SQLite', 'Workflow', 'Utilities', 'DB Access', 'Access all', 'Migrations in Git', 'Execute gate', 'Backup & Restore', 'Backup commands']; | ||
|
|
||
| // Metadata table → owning feature, column count (schema.ts, 31 migrations). | ||
| const TABLES = [ |
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.
What
docs/feature-map.htmlis generated, but its sources lived only in one session's scratch folder, so any change meant hand-editing the generated page. This PR moves them in:docs/feature-map/template.html,data.jsandapp.js: the layout, the inventory and the page script.scripts/feature-map/build.mjsfills in the Mermaid diagrams fromdocs/FEATURE_MAP.mdand writesdocs/feature-map.html. Run it withnpm run docs:feature-map.--board <file>also writes the planning-board page that is published as an Artifact.FEATURE_MAP.md's "Keeping this page true" section says where to edit and how to rebuild.The build reproduces today's
docs/feature-map.htmlbyte for byte, so the page itself is unchanged here.Tests
packages/shared/src/feature-map-build.test.tschecks:$in the sources stays literalA/B: two of the tests fail with plain-string replacement and no range check. Lint, security lint and
tscare clean.Note
#563 (a Cursor agent's docs PR) hand-edits
docs/feature-map.html. Its text doesn't conflict with this PR. But once both are in,data.jsshould take #563's numbers, or the next rebuild drops them. I'll do that in a follow-up, together with adding SQL Tracer to the page.🤖 Generated with Claude Code
Note
Low Risk
Docs-only tooling and generated HTML; no runtime product code paths change. Main risk is build/template drift if
FEATURE_MAP.mddiagrams are reordered without updating placeholders.Overview
Moves the interactive feature map from a hand-edited generated file into maintainable sources, so inventory and UI logic can change without patching
docs/feature-map.htmldirectly.Adds
docs/feature-map/(template.html,data.js,app.js) andscripts/feature-map/build.mjs, which inlines inventory and app script, pulls Mermaid blocks fromdocs/FEATURE_MAP.mdinto__M<n>__slots (with HTML escaping and a fail-fast check if template and doc drift), and writes the repo copy vianpm run docs:feature-map. The static output setsFOX_MAP_STATIC(no shared Plan board) and loads pinned Mermaid from CDN;--board <file>emits the full planning-board page for Artifact publish.FEATURE_MAP.mdnow documents where to edit and how to rebuild.packages/shared/src/feature-map-build.test.tscovers diagram placement/escaping, literal$in sources, missing-diagram errors, and the static HTML wrapper.Reviewed by Cursor Bugbot for commit 9347a65. Bugbot is set up for automated code reviews on this repo. Configure here.