Repository navigation
fix(docs): migrate to astro 6 content collection config - #1345
Merged
tamirdresher merged 1 commit intoJun 15, 2026
Merged
Conversation
- Move docs/src/content/config.ts -> docs/src/content.config.ts (Astro 6 requires the content config at src/content.config.ts, not inside src/content/) - Replace deprecated ViewTransitions import with ClientRouter from astro:transitions (also removed in Astro 6) - Update generated .astro/ type stubs to match new collection layout Fixes the LegacyContentConfigError introduced by PR github#1332 (astro 6.4.7 bump). dev CI has been failing since 19:35 UTC 2026-06-15 at: https://github.com/bradygaster/squad/actions/runs/27571236144 Note: the markdown.remarkPlugins / rehypePlugins deprecation warning visible in the build output is intentionally NOT addressed in this PR (separate concern). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
🟢 Impact Analysis — PR #1345Risk tier: 🟢 LOW 📊 Summary
🎯 Risk Factors
📦 Modules Affecteddocs (5 files)
This report is generated automatically for every PR. See #733 for details. |
Contributor
🛫 PR Readiness Check
PR Scope: 🔧 Infrastructure
|
| Status | Check | Details |
|---|---|---|
| ✅ | Single commit | 1 commit — clean history |
| ✅ | Not in draft | Ready for review |
| ✅ | Branch up to date | Up to date with dev |
| ❌ | Copilot review | No Copilot review yet — it may still be processing |
| ✅ | Changeset present | No source files changed — changeset not required |
| ✅ | Scope clean | No .squad/ or docs/proposals/ files |
| ✅ | No merge conflicts | No merge conflicts |
| ✅ | Copilot threads resolved | No Copilot review threads |
| ❌ | CI passing | 6 check(s) still running |
Files Changed (5 files, +99 −179)
| File | +/− |
|---|---|
docs/.astro/collections/blog.schema.json |
+31 −49 |
docs/.astro/collections/docs.schema.json |
+31 −49 |
docs/.astro/content.d.ts |
+35 −79 |
docs/src/content.config.ts |
+0 −0 |
docs/src/layouts/BaseLayout.astro |
+2 −2 |
Total: +99 −179
This check runs automatically on every push. Fix any ❌ items and push again.
See CONTRIBUTING.md and PR Requirements for details.
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes the docs site build after the Astro 6 upgrade by migrating the content collection config to Astro 6’s expected location and updating transitions usage, along with regenerating the Astro content type/schema stubs.
Changes:
- Move content collection config to
docs/src/content.config.tsand definedocs+blogcollections usingastro/loaders. - Replace removed
ViewTransitionswithClientRouterfromastro:transitions. - Update generated
docs/.astro/content typings and JSON schemas to match the new config/layout.
Reviewed changes
Copilot reviewed 3 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| docs/src/layouts/BaseLayout.astro | Switch transitions component from ViewTransitions to ClientRouter for Astro 6 compatibility. |
| docs/src/content.config.ts | Introduce Astro 6-compatible content collection config at the src/ root using loader-based collections. |
| docs/.astro/content.d.ts | Regenerated content-collection type stubs to match the new config path and collection model. |
| docs/.astro/collections/docs.schema.json | Regenerated docs collection schema reflecting the updated config/tooling output. |
| docs/.astro/collections/blog.schema.json | Regenerated blog collection schema reflecting the updated config/tooling output. |
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 free
to 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.
What changed
docs/src/content/config.ts→docs/src/content.config.tsAstro 6 expects the content collection config at
src/content.config.ts(at thesrc/root), not insidesrc/content/. Leaving the file in the old location triggers a fatalLegacyContentConfigErrorand aborts the build.ViewTransitionsimport withClientRouterfromastro:transitionsViewTransitionswas removed in Astro 6;ClientRouteris the replacement.docs/.astro/type stubs to reflect the new collection layout.Why
PR #1332 bumped Astro from 5.18.0 to 6.4.7. dev CI has been failing since 19:35 UTC on 2026-06-15:
Failing run: https://github.com/bradygaster/squad/actions/runs/27571236144
What is NOT in this PR
The
markdown.remarkPlugins/rehypePluginsdeprecation warning visible in the build output is a soft warning — it does not fail the build. It is intentionally deferred to a follow-up PR to keep this change scoped.Local validation
All 22 tests in
test/docs-build.test.tspass: