[docs] Update Astro dependencies - 2026-06-24#41258
Conversation
Update npm packages in docs/ to latest versions.
- astro: ^6.4.6 → ^7.0.2 (major)
- @astrojs/starlight: ^0.40.0 → ^0.41.0 (minor)
- astro-mermaid: ^2.0.2 → ^2.0.4 (patch)
- sharp: ^0.35.1 → ^0.35.2 (patch)
- @playwright/test: ^1.61.0 → ^1.61.1 (patch)
- starlight-github-alerts: ^0.2.0 → ^0.3.0 (minor)
Migration (Astro 7): Move markdown.remarkPlugins / rehypePlugins
into unified({...}) from @astrojs/markdown-remark, per the
new processor API. Adds @astrojs/markdown-remark as a direct
dependency.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅ |
|
✅ Test Quality Sentinel completed test quality analysis. No test files were added or modified in this PR. Test Quality Sentinel skipped. PR #41258 only updates Astro documentation dependencies (docs/astro.config.mjs, docs/package.json, docs/package-lock.json). |
|
✅ PR Code Quality Reviewer completed the code quality review. |
|
✅ Design Decision Gate 🏗️ completed the design decision gate check. No ADR enforcement needed: PR #41258 does not have the 'implementation' label and has 0 new lines of code in business logic directories (threshold 100). Only 3 files changed, all outside business logic paths. |
There was a problem hiding this comment.
Pull request overview
This PR updates the documentation site (docs/) to Astro 7 and refreshes related npm dependencies, including migrating the Markdown configuration to Astro 7’s processor: unified(...) API via @astrojs/markdown-remark.
Changes:
- Bump
astroto^7.0.2and update related Starlight/build/test dependencies. - Add
@astrojs/markdown-remarkas a direct dependency for the Astro 7 Markdown processor migration. - Update
docs/astro.config.mjsto usemarkdown.processor: unified({ ... })instead of deprecated top-levelremarkPlugins/rehypePlugins.
Show a summary per file
| File | Description |
|---|---|
| docs/package.json | Updates docs dependencies for Astro 7 and adds @astrojs/markdown-remark. |
| docs/package-lock.json | Refreshes the resolved dependency graph for the updated docs toolchain. |
| docs/astro.config.mjs | Migrates Markdown plugin configuration to Astro 7’s processor: unified(...) API. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 2/3 changed files
- Comments generated: 3
| "overrides": { | ||
| "@astrojs/markdown-remark": "^7.2.0" |
There was a problem hiding this comment.
Non-blocking observations on this Astro 6→7 migration. The migration logic is correct and the build passes; two maintainability issues are worth a follow-up.
Findings summary
docs/package.json — duplicate version pin
@astrojs/markdown-remark@^7.2.0 now appears in both dependencies (added here) and overrides (pre-existing). This creates a two-place edit requirement on every future version bump. Either document why both exist or remove the now-redundant override.
docs/astro.config.mjs — unified import name ambiguity
The imported name unified collides with the well-known unified npm package. A one-line comment or alias (createMarkdownProcessor) makes the origin clear for developers unfamiliar with Astro 7's new processor API.
🔎 Code quality review by PR Code Quality Reviewer · 58.2 AIC · ⌖ 7.75 AIC · ⊞ 5.2K
| "starlight-github-alerts": "^0.3.0" | ||
| }, | ||
| "overrides": { | ||
| "@astrojs/markdown-remark": "^7.2.0" |
There was a problem hiding this comment.
Redundant entry: @astrojs/markdown-remark is now pinned in both dependencies and overrides, creating a two-place maintenance burden on every future version bump.
💡 Details
The overrides block was added in a previous commit to force the transitive dependency up to v7.2.x. This PR now also adds it as a direct dependency. These two entries coexist with identical version ranges:
"dependencies": {
"`@astrojs/markdown-remark`": "^7.2.0" // direct dep (added here)
},
"overrides": {
"`@astrojs/markdown-remark`": "^7.2.0" // transitive pin (pre-existing)
}If the override is still needed to force the version for other packages in the dependency tree, it should stay — but a comment explaining that intent would prevent future developers from deleting it as a perceived duplicate. If the override is no longer needed now that there is a direct dependency, it should be removed. As-is, a version bump requires two coordinated edits.
| import starlightBlog from 'starlight-blog'; | ||
| import mermaid from 'astro-mermaid'; | ||
| import { fileURLToPath } from 'node:url'; | ||
| import { unified } from '@astrojs/markdown-remark'; |
There was a problem hiding this comment.
unified is also the name of the popular unified npm package, so this import will confuse developers familiar with the remark/rehype ecosystem but not yet with Astro 7's new processor API.
💡 Suggested fix
Add a clarifying comment or alias to make the origin unmistakable:
// unified() is `@astrojs/markdown-remark`'s processor factory, not the unified npm package
import { unified } from '`@astrojs/markdown-remark`';or use an alias:
import { unified as createMarkdownProcessor } from '`@astrojs/markdown-remark`';
// ...
processor: createMarkdownProcessor({ remarkPlugins: [...], rehypePlugins: [...] }),This removes the guesswork about which unified this is and avoids a naming collision if the actual unified package is ever imported for a custom plugin.
There was a problem hiding this comment.
Skills-Based Review 🧠
Applied /grill-with-docs — approving this clean, well-executed Astro 7 migration.
📋 Key Themes & Highlights
Positive Highlights
- ✅ Correct migration from deprecated
remarkPlugins/rehypePluginstoprocessor: unified({...})following the Astro 7 API - ✅ PR description thoroughly documents all changes, including the known
starlight-blogupstream deprecation warning (outside our control) - ✅ Build verified: 192 pages built, all internal links valid
- ✅ Having
@astrojs/markdown-remarkas both a direct dependency and inoverridesis intentional — the direct dep satisfies the import inastro.config.mjs, while the override forces transitive consumers (e.g.starlight-blog) to also resolve v7.2.0
Minor Observation (Non-Blocking)
starlight-github-alertsbumped from^0.2.0→^0.3.0(minor version). The PR body does not mention what changed in this package. Worth a quick changelog check before merging.
🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · 41.5 AIC · ⌖ 7.88 AIC · ⊞ 6.5K
|
@copilot run pr-finisher skill |
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Done in d803bf6. I ran the PR-finisher flow, pinned |
|
Re-run CI on the current head, then address any lingering non-blocking review comments if needed.
|
Uh oh!
There was an error while loading. Please reload this page.