Skip to content

Commit

Permalink
fix(dev): open to base path (#8123)
Browse files Browse the repository at this point in the history
  • Loading branch information
natemoo-re authored and ematipico committed Aug 21, 2023
1 parent 31a280e commit 2ae9d37
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/popular-carrots-sneeze.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'astro': patch
---

Open to configured `base` when `astro dev --open` runs
4 changes: 3 additions & 1 deletion packages/astro/src/core/dev/container.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,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.
Expand Down

0 comments on commit 2ae9d37

Please sign in to comment.