Skip to content

Point the docs install commands at the flat registry - #16

Merged
mblode merged 2 commits into
mainfrom
claude/drop-legacy-styles-mirror
Aug 18, 2026
Merged

Point the docs install commands at the flat registry#16
mblode merged 2 commits into
mainfrom
claude/drop-legacy-styles-mirror

Conversation

@mblode

@mblode mblode commented Aug 18, 2026

Copy link
Copy Markdown
Owner

AGENTS.md names the legacy /r/styles/default/ mirror as the most likely objection to the shadcn directory submission (shadcn-ui/ui#11543), and 77 component docs still sent readers through it.

The legacy path only resolves via a redirect:

/ui/r/styles/default/field   308 -> /ui/r/styles/default/field.json
/ui/r/field.json             200

So every install command in the docs cost a hop through the mirror the submission is trying to retire, when a direct flat equivalent already existed.

Verified

77 files, 76 distinct components. Every rewritten URL was checked against the live site: all 76 return 200 with valid registry JSON. npm run check passes.

Not changed

The registry add step stays in the install docs. @blode isn't listed in shadcn's directory yet, so shadcn add @blode/button still can't resolve on its own.

Stacked on #15, which fixes the served registry.json reporting the wrong namespace.


Note

Medium Risk
Large registry manifest churn and deleting the root registry.json can break consumers or tooling that still expect the old paths or namespace; doc-only URL changes are low risk but affect every install command copy-pasted from the site.

Overview
Component docs now tell readers to run shadcn add against the flat registry endpoints (https://blode.co/ui/r/<name>.json) instead of the legacy /r/styles/default/<name> mirror that only worked via redirect.

public/registry.json is rebuilt to match the current registry layout: a registry:base ui item (theme tokens, @blode URL template), UI entries under registry/default/ui/…, richer metadata, and example registry items removed from the published index. The duplicate root registry.json is dropped so the served manifest is no longer a second hand-maintained copy.

scripts/build-registry.mts writes the same formatted manifest to public/r/registry.json and public/registry.json on every build and includes the latter in post-build formatting.

Reviewed by Cursor Bugbot for commit 7512311. Bugbot is set up for automated code reviews on this repo. Configure here.

mblode and others added 2 commits August 19, 2026 09:49
`registry/index.ts` has said `name: "blode"` for a while, with a comment
explaining that shadcn's directory pairs the registry name with the namespace
(`7ovr` -> `@7ovr`) and that a slash does not resolve. Three files claimed to be
that registry and only one agreed with it:

  public/r/registry.json   name: blode      $schema: yes   85 items  (generated)
  public/registry.json     name: blode/ui   $schema: no   168 items  (stale)
  registry.json            name: blode/ui   $schema: no   168 items  (stale)

`public/registry.json` is what blode.co/ui/registry.json serves, and that is the
URL a directory reviewer opens first. So the advertised registry was announcing
a namespace that contradicts `@blode`, with no `$schema`, while the file the CLI
actually resolves was correct the whole time. Nothing regenerated either stale
copy; `buildRegistryJson` only ever wrote to `public/r`.

It now writes both paths from the same payload, and formats both, so
`npm run check` stays green after a rebuild.

Root `registry.json` is deleted rather than fixed. It sits outside `public/`, so
it is not served; nothing imports it; and the only `/registry.json` reference in
the codebase is app/api/well-known/api-catalog, which points at
`${siteUrl}/registry.json` and therefore resolves to the `public/` copy. A stale
duplicate of a generated artefact is what caused this.

Verified after rebuild: both served files report name `blode`, carry `$schema`,
and list 85 items.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
AGENTS.md names the legacy /r/styles/default/ mirror as the most likely
objection to the shadcn directory submission, and 77 component docs still sent
readers through it.

The legacy path only resolves via a redirect:

  /ui/r/styles/default/field  308 -> /ui/r/styles/default/field.json
  /ui/r/field.json            200

So every install command in the docs was costing a hop through the mirror the
submission is trying to retire, when a direct flat equivalent already existed.

77 files, 76 distinct components. Every rewritten URL was checked against the
live site: all 76 return 200 with valid registry JSON.

The `registry add` step stays in the install docs. `@blode` is still not listed
in shadcn's directory, so `shadcn add @blode/button` cannot resolve on its own
yet.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Aug 18, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
blode-ui Ignored Ignored Preview Aug 18, 2026 11:52pm

Request Review

@mblode
mblode marked this pull request as ready for review August 18, 2026 23:54
@mblode
mblode merged commit 0276a8f into main Aug 18, 2026
3 checks passed
@mblode
mblode deleted the claude/drop-legacy-styles-mirror branch August 18, 2026 23:54
@cursor

cursor Bot commented Aug 18, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot 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: serverGenReqId_5f735c3e-0c0a-4a61-b854-d9d7e3f6b0a3)

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