Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Astro 5 beta #1329

Merged
merged 3 commits into from
Oct 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/cyan-wasps-jump.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@keystatic/astro': patch
---

Remove check for `output: 'hybrid'` or `output: 'server'` to support Astro 5
2 changes: 1 addition & 1 deletion packages/astro/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
},
"peerDependencies": {
"@keystatic/core": "*",
"astro": "2 || 3 || 4",
"astro": "2 || 3 || 4 || 5",
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
Expand Down
5 changes: 0 additions & 5 deletions packages/astro/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,6 @@ export default function keystatic(): AstroIntegration {
name: 'keystatic',
hooks: {
'astro:config:setup': ({ injectRoute, updateConfig, config }) => {
if (config.output === 'static') {
throw new Error(
"Keystatic requires `output: 'hybrid'` or `output: 'server'` in your Astro config"
);
}
updateConfig({
server: config.server.host ? {} : { host: '127.0.0.1' },
vite: {
Expand Down
Loading