Uh oh!
There was an error while loading. Please reload this page.
docs(runner): 删掉 Best Practices 里复活的环境变量配置面 (#3617) - #3633
Merged
Conversation
#3538(039d2d0,Fixes#3533)以「文档不许描述不存在的能力」为由删掉了本页的 `## Environment Variables` 整节,但只删了那一节 —— `## Best Practices` 下的 `### 2. Environment Configuration` 把同一个不存在的配置面又讲了一遍,教读者用 `import.meta.env.VITE_API_URL` / `VITE_ENABLE_ANALYTICS` 配置 Runner。 实现侧不支持这个说法:`grep -rn "import.meta.env|process.env|loadEnv|VITE_" packages/runner` 整包无输出。同页 `## Metadata Loading`(:95)写着相反的话 ——「it reads no environment variables and no config file」,两句相隔约 400 行。 按 #3538 的口径整节删除,而不是换个变量名续命:Runner 没有任何配置面可以承接 它,唯一的配置入口是 `?api=` 查询参数,已由 Metadata Loading 一节完整覆盖。 Best Practices 余下两条,`### 3. Error Boundaries` 顺延为 `### 2.`。 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
The latest updates on your projects. Learn more about Vercel for GitHub. |
yinlianghui
marked this pull request as ready for review
August 7, 2026 16:40
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Aug 7, 2026
akarma-synetal pushed a commit
to akarma-synetal/objectui
that referenced
this pull request
Aug 10, 2026
…bjectstack-ai#3618) (objectstack-ai#3646) `### Add Custom Routes` 让读者 "Edit src/App.tsx" 并给了一段 react-router 代码。 两处与实现相反: 1. `react-router-dom` 不在 `packages/runner/package.json` 的任何依赖里(dependencies 只有 @object-ui/{components,core,plugin-charts,plugin-kanban,react,types} + class-variance-authority / clsx / lucide-react / react / react-dom / tailwind-merge / tailwindcss-animate),全包 grep 'react-router' 零命中 —— 照抄直接 Failed to resolve import。 2. Runner 不是这个路由模型。App.tsx:83 用 useState 持有 currentPath,:120 history.pushState 导航,:127 监听 popstate,:137 把路径喂给 loader.loadPage(currentPath) —— 路由由元数据决定,没有路由表可改。 示例里的 Home / Dashboard / CustomPage 三个组件包里同样不存在。 处置取"保留标题 + 改写为正确说明"而非整节删除:与 objectstack-ai#3538/objectstack-ai#3633 删掉的 `## Environment Variables` / `### 2. Environment Configuration` 不同,那两处描述的 配置面在实现里**不存在**,删掉即无残留问题;而"加路由"是 Runner 真实支持的能力, 只是机制不同(加 JSON 文件),答案就在同页 40 行之下的 `### Add Custom Schemas`。 删掉标题会让按"routes"检索的读者一无所获,并可能重新自行推导出"改 App.tsx"的错误 直觉。本页已有同形态先例:`### Metadata — Supplied by You`(:59)同样是"短说明 + 指向权威小节"的路标节,两处 [Metadata Loading](#metadata-loading) 交叉引用(:63、 :87)也证明页内锚点是本页既有节奏。 `#add-custom-routes` 锚点全仓无任何引用(grep 零命中),故两种处置都不会断链; 保留标题额外保住了站外深链。 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
…ck-ai#3619) (objectstack-ai#3652) (objectstack-ai#3676) objectstack-ai#3619:§Features 的「All official plugins included」与同页 §Pre-installed Plugins 自相矛盾 —— runner 的 dependencies 里只有 plugin-kanban 与 plugin-charts 两个 plugin-*,而仓库里有 19 个 packages/plugin-*。措辞与 PR objectstack-ai#3644 在 README 侧落地的 口径对齐,不留开放集合暗示。 objectstack-ai#3652:三处把 src/main.tsx 指认为插件 import 所在地(§Adding Custom Plugins 第 2 步、 §Use Cases 代码注释、§Troubleshooting 排查步骤),但真实 main.tsx 共 18 行、零个 @object-ui/plugin-* import;side-effect import 在 App.tsx:13-15。Troubleshooting 那处危害最大 —— 排查步骤指向一个永远看不到 import 的文件,既不能证实也不能证伪, 线索到此断掉;改写为可执行的排查动作,并点明 main.tsx 看不到的原因。 §Adding Custom Plugins 的 npm link 建议按 pnpm workspace 实况改写:仅换掉 npm link 仍会留下一份跑不通的步骤 —— 缺 vite.config.ts 别名条目即复现 objectstack-ai#3575 的 HTTP 500。 补齐两个预装插件实际具备的四个接线点(package.json 的 workspace:* 依赖、App.tsx 注册 import、vite.config.ts 别名、index.css 的 @source),与 README(objectstack-ai#3644)一致。 无 changeset:站点文档单文件改动,同页前三次改动(objectstack-ai#3633/objectstack-ai#3646/objectstack-ai#3651)均无。 Claude-Session: https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt Co-authored-by: Claude <noreply@anthropic.com>
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.
Fixes#3617
问题
content/docs/utilities/runner.mdx的## Best Practices下,### 2. Environment Configuration教读者用环境变量配置 Runner:实现侧不支持这个说法。 核查范围是整个包(不只
src):而同一页上方
## Metadata Loading的 :95 写着相反的话:两句在同一页、相隔约 400 行,读者按哪句做都算「照文档做」。
这是 #3538 的漏网
#3538(
039d2d077,Fixes#3533)以「文档不许描述不存在的能力」为由把本页的## Environment Variables整节删除 —— 但只删了那一节,这处 Best Practices 小节把同一个不存在的配置面又讲了一遍。被删那节写的是VITE_API_URL+VITE_APP_TITLE,与本处的VITE_API_URL是同一条。处置
按 #3538 的口径整节删除,而不是换个变量名续命 —— Runner 没有任何配置面可以承接它,唯一的配置入口是
?api=查询参数,已由## Metadata Loading一节完整覆盖。:95那句保留原样:修后全页对「Runner 读不读环境变量」只剩一个声音。编号顺延前后对照
### 1. One File per Page### 1. One File per Page(不动)### 2. Environment Configuration### 3. Error Boundaries### 2. Error Boundaries### 1.已由 #3616 从Modular Schemas改写为One File per Page,本 PR 以最新main(0e4ea07b2)重锚定,按内容定位而非行号。验证(先预测后验证,四条全中)
grep -n 'VITE_|import.meta.env|process.env' content/docs/utilities/runner.mdx0 命中(修前 2 命中):95的 "reads no environment variables" 原样保留95:setting — it reads no environment variables and no config file:node scripts/check-doc-links.mjs修前修后都绿Links are valid across 6 scan roots.exit 0node scripts/check-control-bytes.mjs绿 + 改动文件自扫干净OK (scanned 3654 tracked text file(s); skipped 85 binary);grep -naP '[\x00-\x08\x0b\x0c\x0e-\x1f]'零命中另核:全仓无任何位置引用被删小节的锚点
#2-environment-configuration(grep -rni零命中),故 doc-links 修前修后同绿不是「没扫到」。本 PR 只删不增链接。content/**-only 的 PR 会跳过ci.yml/lint.yml(两者的paths-ignore都含content/**),真正会跑的门禁正是上表后两条 ——docs-links.yml与control-bytes.yml。范围
content/docs/utilities/runner.mdx,单个 diff hunk(@@ -491,14 +491 @@)。### Add Custom Routes(:409,那是 content/docs/utilities/runner.mdx §Add Custom Routes 教读者用 react-router-dom 改写 App.tsx,但 runner 不依赖它,路由是手写的 history.pushState #3618,同文件互斥,等本单落 main 另派)。packages/runner/README.md(packages/runner/README.md §Features 的「Hot Reload - Automatic reload on schema changes」未按 loader 分路,?api=那条不成立 #3620 在途)。content/,不涉及任何已发布包的行为;@object-ui/site本就在.changeset/config.json的ignore列表内。🤖 Generated with Claude Code
https://claude.ai/code/session_01GTRjn8xBqp75dk7kFupVRt
Generated by Claude Code