0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2024-12-16 21:46:22 -05:00

fix(dev): open to base path (#8123)

This commit is contained in:
Nate Moore 2023-08-17 16:51:08 -05:00 committed by GitHub
parent 1b656233b3
commit 1f6497c334
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 1 deletions

View file

@ -0,0 +1,5 @@
---
'astro': patch
---
Open to configured `base` when `astro dev --open` runs

View file

@ -56,7 +56,9 @@ export async function createContainer({
settings = injectImageEndpoint(settings);
}
const { host, headers, open } = settings.config.server;
const { base, server: { host, headers, open: shouldOpen }} = settings.config;
// Open server to the correct path
const open = shouldOpen ? base : false;
// The client entrypoint for renderers. Since these are imported dynamically
// we need to tell Vite to preoptimize them.