Skip to content

fix(docs,scripts): 清掉 9 条包 README 死链,并让链接门禁认站内绝对 URL (#3603) - #3629

Merged
yinlianghui merged 2 commits into
mainfrom
claude/issue-3603-pkg-readme-links
Aug 7, 2026
Merged

fix(docs,scripts): 清掉 9 条包 README 死链,并让链接门禁认站内绝对 URL (#3603)#3629
yinlianghui merged 2 commits into
mainfrom
claude/issue-3603-pkg-readme-links

Conversation

@yinlianghui

Copy link
Copy Markdown
Collaborator

Fixes-part-of #3603

分段交付。内容半件全交;门禁半件只交第 2 层(judgeHref 解析站内绝对 URL),第 1 层(SCAN_ROOTS 追加包 README)按实测结论回队列,单独开在 #3622 —— 理由在第四节,是本 PR 最需要复核的判断。

PM 裁决要求的前置实测已做:git log origin/main 确认 #3589 已落 main(6632114bc,SCAN_ROOTS 打印 6 roots),worktree 基线即含它,门禁半件不与任何在途 PR 同文件。


一、内容半件:9 条逐条处置

按 fumadocs 候选拼写(x.mdx / x.md / x/index.mdx / x/index.md)在 content/docs 下逐个查证。查不到对应文档页的删该行(指向不存在的页面比不给链接更糟,分诊已确认此 fallback);查到的改指真实页。

位置原链接处置依据
packages/auth/README.md:223/docs/packages/auth删行全库无 @object-ui/auth 的文档页;AuthProvider / AuthGuardcontent/docs 零命中。blocks/authentication.mdx 是「Authentication Blocks」登录表单 block 图库,与本包(Provider、守卫、token)不是一个主题,指过去会误导
packages/collaboration/README.md:132/docs/packages/collaboration删行无文档页;LiveCursors / PresenceAvatars 零命中
packages/i18n/README.md:152/docs/packages/i18n删行无文档页;useObjectTranslation 仅在 guide/public-forms.md 顺带出现,I18nProvider 仅在 architecture-overview / troubleshooting 顺带出现,都不是 i18n 的文档页
packages/mobile/README.md:143/docs/packages/mobile删行无文档页;useBreakpoint / MobileProvider 零命中
packages/permissions/README.md:137/docs/packages/permissions删行无文档页;PermissionGuard / usePermissions 零命中
packages/providers/README.md:82/docs/packages/providers删行无文档页
packages/react/README.md:243/docs/packages/react改指 /docs/core/schema-rendererissue 提示「react 的文档可能在 content/docs/core/ 一带」,查证属实:core/schema-renderer.mdx 标题 "SchemaRenderer"、描述 "Core component for rendering JSON schemas into React components",正是本包 README 开篇自述的头号导出
packages/vscode-extension/README.md:188/docs/protocol/overview改指 /docs/api/schema-reference该行标签就是 "Schema Reference",api/schema-reference.md 标题正是 "Schema Type Reference"
packages/vscode-extension/README.md:189/docs/api/components改指 /docs/components该行标签是 "Component Library",components/index.md 标题正是 "Component Gallery"(packages/components/README.md 早已用这条路由)

6 删 3 改。删掉的那 6 行所在的 ## Links 尾块保留其余 5 条(npm / Changelog / Issues / Contributing / Roadmap),README 正文本身就是这些包当前的文档。

顺带说明:这 7 个包共同假设了一个不存在的 /docs/packages/* 命名空间。删链接只是止血,真正的修法是把这些页面写出来;这属另一件事,已在 #3622 末尾记录供分诊判断是否另开。

复核脚本(issue 正文同款,改为对工作树跑)输出:dead links: 0

二、门禁半件第 2 层:站内绝对 URL 解回站内路由

judgeHref() 此前对任何带 scheme 的 href 直接 return null,唯一例外是 SELF_REPO_BLOB_RE。于是 https://www.objectui.org/docs/guide/plugins 从不校验,而同一条路由写成 /docs/guide/plugins 则严格校验 —— 两者只差一个 origin,而 origin 恰恰是这个脚本唯一能确定的部分。

实现是通用的,不特判包 README:剥掉 origin,把剩下的绝对站内路径原样交给同一个 routeExists()。因此两个分支都原样继承 —— /docs 的严格性(.../docs/guide/foo.md 被拒的理由与 /docs/guide/foo.md 完全相同)与 apps/site 路由表(/examples 无路由则拒)。这一点在测试里是两条 INHERITS ... 断言,实现若改成"另起一套判断"它们会红。

两种 host 拼写都认(本仓 www.objectui.org 与裸 objectui.org 都在用);正则两端锚定,objectui.org.example.com 这种仿冒 host 不会误借本仓路由表(有专门一条测试)。

落地前实测:全部扫描面共 11 条站内绝对 URL,零死链 —— 与 #3589 同形状(门禁到货即绿),对照 #3479(16 个死目标)/ #3490(18 个)那种「门禁与欠账同时到货」。其中 6 条就在 content/docs 自己,这正是分诊说的「这一层对所有扫描面都成立」—— 不是包 README 专属问题。

反空绿

本次没有新增扫描根,所以既有的仓库级 "has no broken internal links" 断言即使解析层完全不干活也照样绿。为此新增一条计数下限:实测 11 条(其中 content/docs 贡献 6 条、带 /docs 路径 3 条)必须真的被 siteAbsoluteRoute() 认出来,否则上面那条绿毫无意义。这是本 PR 最重要的一条测试。

新增/改写:8 条新 case,既有 labels all seven checks distinctly 扩成 eight、HINTS 键表扩成 8 键。

三、逆向验证(方向先定,后跑)

预测方向为常规方向(改前绿 / 改后红),理由:这是对一个此前被 EXTERNAL_HREF_RE 无条件跳过的形状新增的检查 —— 既不存在 canonical-first 的 ?? 链(故不属 inverted 家族),新判定喂的也是谓词而非计数(故不属「诊断变多」家族)。

步骤状态预测实测
1content/docs/index.md 与根 README.md 各植入一条死的站内绝对 URL,解析层红,reason 为 site-absolute-url,两个面各一条Found 2 broken links —— [site-absolute-url] content/docs/index.md:89 + [site-absolute-url] README.md:518,hint 正常打印
2保留植入,撤掉judgeHref 里的解析分支绿(证明是新层在干活,不是既有检查顺手抓到的)Links are valid across 6 scan roots. exit=0 —— 两条死链被静默放行,正是改前行为
3撤掉解析分支的状态下跑测试新测试应大面积红✅ 7 failed / 68 passed(accept 侧与纯函数用例本就该继续绿)
4全部还原绿,且工作树只剩本 PR 的文件Links are valid across 6 scan roots.,git status 干净

四、⚠️ 门禁半件第 1 层没有做 —— 请优先复核这一节

PM 的预测是「内容半件清干净后,门禁首跑对真仓应为绿」。这个预测对第 2 层成立,对第 1 层被实测证伪,所以我停在文件面边界上,没有硬凑。

在 9 条已清干净之后,把 disk 规则的包 README 扫描根加上去,仍会红 11 条,分布在本单文件面之外的 5 个包(components / core / fields / layout / types),外加 react、vscode-extension 各一条不同的行:/api/core/api/react/api/components(无此路由)、/docs/core/docs/fields/docs/layout(真目录但无 index 页,故无路由)、/docs/types/examples(均不存在),以及两条磁盘路径 ../../docs/SHADCN_SYNC.md./LICENSE(文件不在)。

其中 /docs/core/docs/fields/docs/layout 值得单独点名:issue 正文的复核脚本把它们判成了绿,因为那段脚本把裸目录也算作 fumadocs 候选(候选数组的最后一项 rel)。门禁不这么算,而且它是对的 —— routeCandidates() 只有四种拼写,既有 pin 测试 rejects a relative link to a directory that has no index page 就是这条规则。实测 content/docs/core / fields / layout / rfcs 确实没有 index 页。所以这一类的真实规模是 20 条,不是 9 条。

按本文件头注释自 #3572 起写死的规矩 ——「先量扫描面,单独付清红账,再加那一行」—— 红账应单独付,故第 1 层连同它的 11 条欠账开在 #3622(已挂为 #3603 的子 issue,自动进派发池)。头注释里新增了一节 "Measured and NOT bought",把这个测量结果和 issue 编号写死,避免下一个人不量就加行、撞上一片意外的红。

文件面偏差(1 个文件,主动声明)

content/docs/guide/ci-cd-pipeline.md 不在派发单列出的文件面里,但本 PR 改了它:该页用一张表逐条描述这个门禁判定哪些 href 形状,原文写「Four checks, by href shape」,我的改动使其变成事实错误。#3589 改同一处行为时也同步改了这个文件(它是那次 diff 的三个文件之一),AGENTS.md 准则 #2「docs 不反映代码就不算完成」也指向同一结论。改动限于新增跨扫描面两形状的说明表 + 一处覆盖面描述,未动其它内容;已确认无在途 PR 触碰该文件。若判定越界,可要求我拆出。

五、验证

$ node scripts/check-doc-links.mjs
Links are valid across 6 scan roots.
$ pnpm vitest run scripts/__tests__/check-doc-links.test.ts --maxWorkers=2
Test Files 1 passed (1)
Tests 75 passed (75)
$ pnpm vitest run scripts/__tests__/ --maxWorkers=2
Test Files 16 passed (16)
Tests 293 passed (293)
$ pnpm type-check:scripts
exit=0
$ node scripts/check-control-bytes.mjs
✅ check-control-bytes: OK (scanned 3650 tracked text file(s); skipped 85 binary)

消费半径清点:check-doc-links 的消费方为 docs-links.yml / ci.yml / check-links.ymlCONTRIBUTING.mdcontent/docs/guide/ci-cd-pipeline.mdlychee.toml 与 3 个测试文件,全部跑过或核对过。CONTRIBUTING.md 明确写着「read them there instead of trusting a list copied into prose」,无需同步。

changeset:不加,与仓例一致 —— #3602(纯 README 死链修复)与 #3589(纯门禁脚本 + 测试)都没有 changeset。


Generated by Claude Code

内容半件:9 条 `/docs/packages/*` 等死链逐条查证后处置 —— 6 条查无对应
文档页(auth / collaboration / i18n / mobile / permissions / providers)
删掉该行,3 条改指真实页(react → /docs/core/schema-renderer,
vscode-extension 的 Schema Reference → /docs/api/schema-reference、
Component Library → /docs/components)。
门禁半件第 2 层:`judgeHref()` 此前对任何带 scheme 的 href 直接放行,
所以写成本站绝对 URL 的路由从不校验,而同一条路由写成 `/docs/...` 则严格
校验。现在剥掉 origin 后交给同一个 `routeExists()`,`/docs` 的严格性与
`apps/site` 路由表原样继承。这是通用修复而非包 README 特判:`content/docs`
自己就写了 6 条这种 URL。落地前实测 11 条、零死链。
门禁半件第 1 层(SCAN_ROOTS 追加包 README)**未做**,理由见 #3622:
先量后付的仓规下,实测那一行会额外红 11 条,分布在本单从未触及的 5 个包。
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
@vercel

vercelBot commented Aug 7, 2026

Copy link
Copy Markdown

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

1 Skipped Deployment
ProjectDeploymentActionsUpdated (UTC)
objectuiIgnoredIgnoredAug 7, 2026 4:24pm

Request Review

@github-actions

Copy link
Copy Markdown
Contributor

✅ Console Performance Budget

MetricValueBudget
Main entry (gzip)28.1 KB350 KB
Entry fileindex-DBwr6kyx.js
StatusPASS

📦 Bundle Size Report

PackageSizeGzipped
app-shell (index.js)8.66KB3.13KB
app-shell (runtime-config.js)7.42KB2.32KB
app-shell (types.js)0.01KB0.04KB
app-shell (urlParams.js)7.57KB2.97KB
auth (AuthContext.js)0.31KB0.24KB
auth (AuthGuard.js)1.17KB0.53KB
auth (AuthProvider.js)22.10KB4.37KB
auth (AuthShell.js)3.49KB1.40KB
auth (ForgotPasswordForm.js)12.21KB3.45KB
auth (LoginForm.js)18.13KB5.39KB
auth (PreviewBanner.js)0.90KB0.50KB
auth (RegisterForm.js)6.64KB2.21KB
auth (SocialSignInButtons.js)9.60KB3.89KB
auth (UserMenu.js)3.40KB1.22KB
auth (auth-gate-events.js)1.29KB0.66KB
auth (authStyles.js)5.04KB1.72KB
auth (createAuthClient.js)35.76KB9.11KB
auth (createAuthenticatedFetch.js)4.37KB1.69KB
auth (index.js)2.35KB1.07KB
auth (org-roles.js)6.66KB2.78KB
auth (phone-identifier.js)1.11KB0.66KB
auth (types.js)0.59KB0.35KB
auth (useAuth.js)4.91KB0.87KB
auth (useIsWorkspaceAdmin.js)1.61KB0.85KB
collaboration (CommentThread.js)26.07KB7.56KB
collaboration (LiveCursors.js)3.17KB1.27KB
collaboration (PresenceAvatars.js)6.49KB2.64KB
collaboration (PresenceProvider.js)2.79KB1.13KB
collaboration (index.js)1.65KB0.73KB
collaboration (useCollaborationTranslation.js)6.05KB2.52KB
collaboration (useCommentSearch.js)1.98KB0.88KB
collaboration (useConflictResolution.js)7.75KB1.86KB
collaboration (useMentionNotifications.js)1.81KB0.68KB
collaboration (usePresence.js)6.33KB1.84KB
collaboration (useRealtimeSubscription.js)7.91KB2.01KB
components (index.js)480.72KB105.64KB
core (index.js)2.96KB1.13KB
create-plugin (index.js)9.28KB2.98KB
data-objectstack (index.js)137.51KB35.11KB
fields (index.js)230.87KB56.83KB
i18n (LocalizationContext.js)1.76KB0.96KB
i18n (currency.js)1.22KB0.64KB
i18n (i18n.js)4.32KB1.77KB
i18n (index.js)2.65KB1.06KB
i18n (pickLocalized.js)1.70KB0.83KB
i18n (provider.js)9.48KB3.27KB
i18n (useObjectLabel.js)26.14KB6.07KB
i18n (useSafeTranslation.js)4.52KB1.96KB
layout (index.js)38.53KB10.71KB
mobile (MobileProvider.js)0.92KB0.49KB
mobile (ResponsiveContainer.js)0.94KB0.38KB
mobile (breakpoints.js)1.51KB0.70KB
mobile (createOfflineDataSource.js)5.61KB1.74KB
mobile (index.js)1.50KB0.62KB
mobile (offlineQueue.js)3.91KB1.35KB
mobile (pwa.js)0.97KB0.49KB
mobile (serviceWorker.js)1.48KB0.62KB
mobile (serviceWorkerSource.js)3.41KB1.48KB
mobile (useBreakpoint.js)1.54KB0.65KB
mobile (useGesture.js)6.96KB1.98KB
mobile (useOfflineSync.js)1.99KB0.72KB
mobile (usePullToRefresh.js)2.53KB0.85KB
mobile (useResponsive.js)0.71KB0.42KB
mobile (useResponsiveConfig.js)1.36KB0.63KB
mobile (useSpecGesture.js)4.32KB1.64KB
mobile (useTouchTarget.js)1.01KB0.54KB
permissions (MePermissionsProvider.js)8.75KB3.06KB
permissions (PermissionContext.js)0.31KB0.25KB
permissions (PermissionGuard.js)0.89KB0.45KB
permissions (PermissionProvider.js)3.67KB1.12KB
permissions (evaluator.js)4.41KB1.44KB
permissions (index.js)0.91KB0.41KB
permissions (store.js)0.91KB0.42KB
permissions (useFieldPermissions.js)1.28KB0.52KB
permissions (usePermissions.js)1.55KB0.71KB
plugin-ai (index.js)15.71KB3.79KB
plugin-calendar (index.js)44.98KB12.37KB
plugin-charts (index.js)61.04KB17.31KB
plugin-chatbot (index.js)180.09KB42.72KB
plugin-dashboard (index.js)115.50KB29.96KB
plugin-designer (index.js)210.51KB42.51KB
plugin-detail (index.js)232.79KB57.42KB
plugin-editor (index.js)2.46KB1.10KB
plugin-form (index.js)112.10KB27.10KB
plugin-gantt (index.js)162.55KB39.57KB
plugin-grid (index.js)186.61KB49.34KB
plugin-kanban (index.js)48.30KB13.28KB
plugin-list (index.js)105.12KB25.48KB
plugin-map (index.js)16.81KB5.24KB
plugin-markdown (index.js)13.72KB4.69KB
plugin-report (index.js)40.58KB10.58KB
plugin-timeline (index.js)25.76KB7.33KB
plugin-tree (index.js)8.50KB2.88KB
plugin-view (index.js)84.03KB20.55KB
providers (DataSourceProvider.js)0.75KB0.39KB
providers (MetadataProvider.js)1.37KB0.59KB
providers (ThemeProvider.js)1.90KB0.85KB
providers (UploadProvider.js)11.71KB3.53KB
providers (index.js)0.44KB0.22KB
providers (types.js)0.01KB0.04KB
react-runtime (index.js)5.67KB2.37KB
react (LazyPluginLoader.js)3.77KB1.33KB
react (SchemaRenderer.js)19.28KB6.38KB
react (data-invalidation.js)5.05KB2.08KB
react (index.js)1.02KB0.55KB
react (spec-input.js)0.20KB0.18KB
sdui-parser (codegen.js)4.09KB1.74KB
sdui-parser (index.js)4.47KB2.03KB
sdui-parser (parse.js)10.04KB2.82KB
sdui-parser (types.js)0.29KB0.24KB
sdui-parser (validate.js)4.69KB1.48KB
types (ai.js)0.20KB0.17KB
types (api-types.js)0.20KB0.18KB
types (app.js)2.87KB0.99KB
types (base.js)0.20KB0.18KB
types (blocks.js)0.20KB0.18KB
types (complex.js)0.20KB0.18KB
types (crud.js)0.20KB0.18KB
types (data-display.js)0.20KB0.18KB
types (data-protocol.js)0.20KB0.19KB
types (data.js)0.20KB0.18KB
types (designer.js)1.87KB0.85KB
types (disclosure.js)0.20KB0.18KB
types (error-code.js)1.54KB0.88KB
types (feedback.js)0.20KB0.18KB
types (field-types.js)0.20KB0.18KB
types (form.js)0.20KB0.18KB
types (http-retry.js)4.32KB2.02KB
types (index.js)2.71KB1.34KB
types (layout.js)0.20KB0.18KB
types (managed-by.js)0.19KB0.18KB
types (mobile.js)2.59KB1.31KB
types (navigation.js)0.20KB0.18KB
types (objectql.js)0.20KB0.18KB
types (overlay.js)0.20KB0.18KB
types (permissions.js)0.20KB0.18KB
types (plugin-scope.js)0.20KB0.18KB
types (record-components.js)0.20KB0.19KB
types (record-semantics.js)1.28KB0.67KB
types (registry.js)0.20KB0.18KB
types (reports.js)0.20KB0.18KB
types (spec-report.js)5.05KB1.93KB
types (system-fields.js)3.33KB1.54KB
types (theme.js)0.20KB0.18KB
types (ui-action.js)3.40KB1.71KB
types (views.js)0.20KB0.18KB
types (widget.js)0.20KB0.18KB

Size Limits

  • ✅ Core packages should be < 50KB gzipped
  • ✅ Component packages should be < 100KB gzipped
  • ⚠️ Plugin packages should be < 150KB gzipped

@github-actions

Copy link
Copy Markdown
Contributor

✅ Console Performance Budget

MetricValueBudget
Main entry (gzip)28.1 KB350 KB
Entry fileindex-BWAy3DWK.js
StatusPASS

📦 Bundle Size Report

PackageSizeGzipped
app-shell (index.js)8.66KB3.13KB
app-shell (runtime-config.js)7.42KB2.32KB
app-shell (types.js)0.01KB0.04KB
app-shell (urlParams.js)7.57KB2.97KB
auth (AuthContext.js)0.31KB0.24KB
auth (AuthGuard.js)1.17KB0.53KB
auth (AuthProvider.js)22.10KB4.37KB
auth (AuthShell.js)3.49KB1.40KB
auth (ForgotPasswordForm.js)12.21KB3.45KB
auth (LoginForm.js)18.13KB5.39KB
auth (PreviewBanner.js)0.90KB0.50KB
auth (RegisterForm.js)6.64KB2.21KB
auth (SocialSignInButtons.js)9.60KB3.89KB
auth (UserMenu.js)3.40KB1.22KB
auth (auth-gate-events.js)1.29KB0.66KB
auth (authStyles.js)5.04KB1.72KB
auth (createAuthClient.js)35.76KB9.11KB
auth (createAuthenticatedFetch.js)4.37KB1.69KB
auth (index.js)2.35KB1.07KB
auth (org-roles.js)6.66KB2.78KB
auth (phone-identifier.js)1.11KB0.66KB
auth (types.js)0.59KB0.35KB
auth (useAuth.js)4.91KB0.87KB
auth (useIsWorkspaceAdmin.js)1.61KB0.85KB
collaboration (CommentThread.js)26.07KB7.56KB
collaboration (LiveCursors.js)3.17KB1.27KB
collaboration (PresenceAvatars.js)6.49KB2.64KB
collaboration (PresenceProvider.js)2.79KB1.13KB
collaboration (index.js)1.65KB0.73KB
collaboration (useCollaborationTranslation.js)6.05KB2.52KB
collaboration (useCommentSearch.js)1.98KB0.88KB
collaboration (useConflictResolution.js)7.75KB1.86KB
collaboration (useMentionNotifications.js)1.81KB0.68KB
collaboration (usePresence.js)6.33KB1.84KB
collaboration (useRealtimeSubscription.js)7.91KB2.01KB
components (index.js)480.72KB105.64KB
core (index.js)2.96KB1.13KB
create-plugin (index.js)9.28KB2.98KB
data-objectstack (index.js)137.51KB35.11KB
fields (index.js)230.87KB56.83KB
i18n (LocalizationContext.js)1.76KB0.96KB
i18n (currency.js)1.22KB0.64KB
i18n (i18n.js)4.32KB1.77KB
i18n (index.js)2.65KB1.06KB
i18n (pickLocalized.js)1.70KB0.83KB
i18n (provider.js)9.48KB3.27KB
i18n (useObjectLabel.js)26.14KB6.07KB
i18n (useSafeTranslation.js)4.52KB1.96KB
layout (index.js)38.53KB10.71KB
mobile (MobileProvider.js)0.92KB0.49KB
mobile (ResponsiveContainer.js)0.94KB0.38KB
mobile (breakpoints.js)1.51KB0.70KB
mobile (createOfflineDataSource.js)5.61KB1.74KB
mobile (index.js)1.50KB0.62KB
mobile (offlineQueue.js)3.91KB1.35KB
mobile (pwa.js)0.97KB0.49KB
mobile (serviceWorker.js)1.48KB0.62KB
mobile (serviceWorkerSource.js)3.41KB1.48KB
mobile (useBreakpoint.js)1.54KB0.65KB
mobile (useGesture.js)6.96KB1.98KB
mobile (useOfflineSync.js)1.99KB0.72KB
mobile (usePullToRefresh.js)2.53KB0.85KB
mobile (useResponsive.js)0.71KB0.42KB
mobile (useResponsiveConfig.js)1.36KB0.63KB
mobile (useSpecGesture.js)4.32KB1.64KB
mobile (useTouchTarget.js)1.01KB0.54KB
permissions (MePermissionsProvider.js)8.75KB3.06KB
permissions (PermissionContext.js)0.31KB0.25KB
permissions (PermissionGuard.js)0.89KB0.45KB
permissions (PermissionProvider.js)3.67KB1.12KB
permissions (evaluator.js)4.41KB1.44KB
permissions (index.js)0.91KB0.41KB
permissions (store.js)0.91KB0.42KB
permissions (useFieldPermissions.js)1.28KB0.52KB
permissions (usePermissions.js)1.55KB0.71KB
plugin-ai (index.js)15.71KB3.79KB
plugin-calendar (index.js)44.98KB12.37KB
plugin-charts (index.js)61.04KB17.31KB
plugin-chatbot (index.js)180.09KB42.72KB
plugin-dashboard (index.js)115.50KB29.96KB
plugin-designer (index.js)210.51KB42.51KB
plugin-detail (index.js)232.79KB57.42KB
plugin-editor (index.js)2.46KB1.10KB
plugin-form (index.js)112.10KB27.10KB
plugin-gantt (index.js)162.55KB39.57KB
plugin-grid (index.js)186.61KB49.34KB
plugin-kanban (index.js)48.30KB13.28KB
plugin-list (index.js)105.12KB25.48KB
plugin-map (index.js)16.81KB5.24KB
plugin-markdown (index.js)13.72KB4.69KB
plugin-report (index.js)40.58KB10.58KB
plugin-timeline (index.js)25.76KB7.33KB
plugin-tree (index.js)8.50KB2.88KB
plugin-view (index.js)84.03KB20.55KB
providers (DataSourceProvider.js)0.75KB0.39KB
providers (MetadataProvider.js)1.37KB0.59KB
providers (ThemeProvider.js)1.90KB0.85KB
providers (UploadProvider.js)11.71KB3.53KB
providers (index.js)0.44KB0.22KB
providers (types.js)0.01KB0.04KB
react-runtime (index.js)5.67KB2.37KB
react (LazyPluginLoader.js)3.77KB1.33KB
react (SchemaRenderer.js)19.28KB6.38KB
react (data-invalidation.js)5.05KB2.08KB
react (index.js)1.02KB0.55KB
react (spec-input.js)0.20KB0.18KB
sdui-parser (codegen.js)4.09KB1.74KB
sdui-parser (index.js)4.47KB2.03KB
sdui-parser (parse.js)10.04KB2.82KB
sdui-parser (types.js)0.29KB0.24KB
sdui-parser (validate.js)4.69KB1.48KB
types (ai.js)0.20KB0.17KB
types (api-types.js)0.20KB0.18KB
types (app.js)2.87KB0.99KB
types (base.js)0.20KB0.18KB
types (blocks.js)0.20KB0.18KB
types (complex.js)0.20KB0.18KB
types (crud.js)0.20KB0.18KB
types (data-display.js)0.20KB0.18KB
types (data-protocol.js)0.20KB0.19KB
types (data.js)0.20KB0.18KB
types (designer.js)1.87KB0.85KB
types (disclosure.js)0.20KB0.18KB
types (error-code.js)1.54KB0.88KB
types (feedback.js)0.20KB0.18KB
types (field-types.js)0.20KB0.18KB
types (form.js)0.20KB0.18KB
types (http-retry.js)4.32KB2.02KB
types (index.js)2.71KB1.34KB
types (layout.js)0.20KB0.18KB
types (managed-by.js)0.19KB0.18KB
types (mobile.js)2.59KB1.31KB
types (navigation.js)0.20KB0.18KB
types (objectql.js)0.20KB0.18KB
types (overlay.js)0.20KB0.18KB
types (permissions.js)0.20KB0.18KB
types (plugin-scope.js)0.20KB0.18KB
types (record-components.js)0.20KB0.19KB
types (record-semantics.js)1.28KB0.67KB
types (registry.js)0.20KB0.18KB
types (reports.js)0.20KB0.18KB
types (spec-report.js)5.05KB1.93KB
types (system-fields.js)3.33KB1.54KB
types (theme.js)0.20KB0.18KB
types (ui-action.js)3.40KB1.71KB
types (views.js)0.20KB0.18KB
types (widget.js)0.20KB0.18KB

Size Limits

  • ✅ Core packages should be < 50KB gzipped
  • ✅ Component packages should be < 100KB gzipped
  • ⚠️ Plugin packages should be < 150KB gzipped

@yinlianghui
yinlianghui marked this pull request as ready for review August 7, 2026 16:28
@yinlianghui
yinlianghui added this pull request to the merge queueAug 7, 2026
Merged via the queue into main with commit 0e4ea07Aug 7, 2026
18 checks passed
@yinlianghui
yinlianghui deleted the claude/issue-3603-pkg-readme-links branch August 7, 2026 16:29
akarma-synetal pushed a commit to akarma-synetal/objectui that referenced this pull request Aug 10, 2026
… 条死链 (objectstack-ai#3622) (objectstack-ai#3649)
* feat(scripts): check-doc-links 扫描面第四扩 packages/*/README.md,并付清入场价的 11 条死链 (objectstack-ai#3622)
先量后付的第四次:红账先清零,再加扫描行,门禁首跑对真仓即绿。
11 条死链逐条查证后处置(全部改指实测存在的真实页,零删除):
- 三条 /api/PKG(components/core/react)——站点从来没有这个路由段
(apps/site/app/api 下只有 search/route.ts)。components 改指
/docs/components(Component Gallery,objectstack-ai#3629 给 vscode-extension 用过
的同一页),core 改指 /docs/api(站点自称的 API Reference 总页),
react 改指 /docs/core/schema-renderer(它主导出的参考页)。
- 四条指向 content/docs 下无 index 页的目录(core/fields/layout x2)——
fumadocs 不为裸目录生成路由,objectstack-ai#3603 正文的复核脚本把裸目录也算作候选
才误判为绿。core 改指 /docs/guide/architecture(Package Structure 一节
逐包说明 @object-ui/core),fields 改指 /docs/guide/fields(Field Registry,
正是该包的文档),layout 的 API Reference 改指 /docs/layout/app-shell、
Links 改指 /docs/guide/layout。
- /docs/types 完全不存在 → 改指 /docs/api/schema-reference,该页开头写着
「All types are available from @object-ui/types」。
- /examples 不是站点路由(objectstack-ai#3490 已确认)→ 改指
github.com/objectstack-ai/objectui/tree/main/examples,与
content/docs/utilities/vscode-extension.mdx 里同一条链接的写法一致。
- 两条磁盘路径:docs/SHADCN_SYNC.md 从未存在,真正的完整指南是同包的
README_SHADCN_SYNC.md(278 行);vscode-extension 没有 LICENSE 文件
(39 个包里 4 个没有),按该 README 已有的仓根文件写法改指
blob/main/LICENSE。
扫描行沿用 disk 规则:包 README 在 npm 与 GitHub 上被阅读,相对链接是
磁盘路径语义,与 examples/README/CONTRIBUTING/ROADMAP/docs 同类,无需新
规则类。同一条理由也决定了上面修好的站内链接必须保留 origin——GitHub 与
npm 都把开头的 / 解析到它们自己的域名。
该行是表里唯一带通配符的一条,故 collectFiles 增加 expandWildcard():只
认整段的 *,再复杂的写法直接抛错而不是静默匹配零个路径——扫描面被悄悄
丢掉是这个门禁唯一不能有的失效模式。
测试:SCAN_ROOTS 的 toEqual 与逐根 count 扩写;新根另加「可判定 href 数」
下限(200 条,其中 47 条站内绝对 URL),因为文件数只能证明通配符展开了,
证明不了这批文件里有东西可判;新增 7 条用例覆盖四种死链形状、通配符展开、
只收 README 的边界、packages/node_modules 排除、disk 与 docs 规则的对照对,
以及非整段通配符抛错。
逆向验证(方向先定后跑):植入两条死链(相对磁盘路径 + 站内绝对 URL 各一)
→ 门禁红,正是那 2 条;仅撤掉扫描行、死链留在原地 → 绿,证明是该行在干活;
还原后 7 根全绿。测试层同样验证:撤行后恰好 7 条用例红,唯二直接调
collectFiles 的两条保持绿——与预测一致。
不加 changeset:改的是包 README 的链接与 CI 脚本,不触发任何包的版本
发布,与 objectstack-ai#3589/objectstack-ai#3629 仓例一致。
Fixesobjectstack-ai#3622Fixesobjectstack-ai#3603
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
* docs(scripts): 头注释里 11 条的处置措辞改准 — 全部改指,一条没删
原句写成「Each was resolved to a real page, or dropped where none exists」,
但本次 11 条逐条都找到了实测存在的对位页面,零删除。措辞改准,并点明与
objectstack-ai#3603 那 9 条的差别:那 6 条删掉是因为它们假设了一整个从未写过的
/docs/packages/... 命名空间,本单这 11 条各自都有真实归属。
顺带把「七个包,其中五个 objectstack-ai#3603 从未打开」一句的中英夹缠语序理顺。纯注释,
零行为改动。
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
---------
Co-authored-by: Claude <noreply@anthropic.com>
akarma-synetal pushed a commit to akarma-synetal/objectui that referenced this pull request Aug 10, 2026
…ai#3587) (objectstack-ai#3648) (objectstack-ai#3656)
两处注释称 lychee 是「weekly cron with continue-on-error」,结论「gates
nothing」对,机制反了:check-links.yml 里没有任何 continue-on-error,第 77 行
是 fail: true,`on:` 只有 workflow_dispatch + schedule('17 4 * * 0'),push 与
pull_request 被注释掉并附 ⛔ Do NOT enable(objectstack-ai#3213 ruling B)。按错误理由行事的
人会去摘一行不存在的 continue-on-error,而真实风险相反 —— 取消注释
pull_request: 会让它立刻变成走网络的硬门禁。
改成同一文件 :194 起已有的正确表述(objectstack-ai#3589 头注释措辞):schedule +
workflow_dispatch、无 PR 触发器,所以它谁也拦不住。
同时删掉 judgeHref() 里被逐字复制两遍的那 4 行注释(objectstack-ai#3629 合并时的重复粘贴)。
纯注释改动,零行为变化;test 那处只改说明文字,断言未动。scripts/ 非发布包且
无用户可见变化,故无 changeset。
Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
Co-authored-by: Claude <noreply@anthropic.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationpackage: reacttests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@yinlianghui@claude