Link docs refs across Fedify packages#723
Conversation
Configure the VitePress JSR reference plugin for the Fedify packages whose APIs are referenced throughout the docs, including vocab, webfinger, debugger, testing, and vocab-runtime. Keep separate cache files for each package so the generated indexes do not overwrite each other. Update markdown-it-jsr-ref to a version that chains inline code renderers, which allows multiple package indexes to be active at the same time. Assisted-by: Codex:gpt-5.5
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (3)
📝 WalkthroughWalkthroughUpdates documentation build configuration to support multiple Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@codex review |
There was a problem hiding this comment.
Code Review
This pull request refactors the documentation setup to support multiple JSR packages by dynamically initializing jsrRef plugins for various @fedify packages in docs/.vitepress/config.mts. It also updates the markdown-it-jsr-ref dependency and adds several JSR cache files to docs/.gitignore. Feedback recommends using a wildcard pattern in docs/.gitignore to simplify the file and improve maintainability.
There was a problem hiding this comment.
Pull request overview
Updates the docs site’s Markdown-It configuration so inline code references can link to JSR API docs across multiple Fedify packages, backed by per-package cached indexes.
Changes:
- Load
markdown-it-jsr-refindexes for multiple@fedify/*packages in VitePress Markdown config. - Split JSR ref cache into per-package cache files and ignore them in
docs/.gitignore. - Bump
markdown-it-jsr-reffrom0.4.1to0.4.4.
Reviewed changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| pnpm-lock.yaml | Updates the lockfile for the markdown-it-jsr-ref bump (plus additional dependency/catalog resolution changes). |
| docs/package.json | Bumps markdown-it-jsr-ref to 0.4.4. |
| docs/.vitepress/config.mts | Loads multiple JSR reference indexes and applies all plugin instances to Markdown-It. |
| docs/.gitignore | Ignores the new per-package JSR cache files. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
|
Codex Review: Didn't find any major issues. Bravo. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
Use a wildcard ignore pattern for generated JSR reference cache files so new package-specific caches do not require separate ignore entries. Trim pnpm-lock.yaml so the dependency update only records the markdown-it-jsr-ref version change and avoids unrelated transitive churn. fedify-dev#723 (comment) fedify-dev#723 (comment) Assisted-by: Codex:gpt-5.5
|
@codex review |
|
Codex Review: Didn't find any major issues. What shall we delve into next? ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
Codecov Report✅ All modified and coverable lines are covered by tests. 🚀 New features to boost your workflow:
|
What changed
This updates the VitePress Markdown-It setup in docs/.vitepress/config.mts so
markdown-it-jsr-refloads API indexes for the Fedify packages that are referenced across the docs:@fedify/fedify,@fedify/vocab,@fedify/vocab-runtime,@fedify/webfinger,@fedify/debugger, and@fedify/testing.Each package now gets its own cache file, and those generated cache files are ignored in docs/.gitignore.
This also updates
markdown-it-jsr-reffrom 0.4.1 to 0.4.4 in docs/package.json and pnpm-lock.yaml. The newer version chains inline code renderers correctly, so multiple JSR reference indexes can be active at the same time.Why
The docs had inline code references such as
Create,Object.published,Object.name,~Activity.getObject(), andActivity.fromJsonLd()that should link to JSR API pages but no longer did. Some of those symbols live in@fedify/vocab, not@fedify/fedify, andmarkdown-it-jsr-ref0.4.1 could not safely compose multiple package indexes because each plugin instance replaced the previous inline code renderer.Verification
I checked that
Create,Object.published,Object.name,~Object.names,Activity.fromJsonLd(), andContext.sendActivity()all render as JSR links when the configured package indexes are loaded together.I also verified the rendered docs/manual/vocab.md page in a fresh VitePress dev server and confirmed that the affected inline code references link to the expected JSR API pages.
The commit hook ran
deno fmt --check,hongdown --check,deno check,deno lint, and the workspace protocol check successfully.