diff --git a/packages/astro/src/core/preview/index.ts b/packages/astro/src/core/preview/index.ts index 5aa5d50b9b..221046d39a 100644 --- a/packages/astro/src/core/preview/index.ts +++ b/packages/astro/src/core/preview/index.ts @@ -23,7 +23,7 @@ interface PreviewServer { /** The primary dev action */ export default async function preview(config: AstroConfig, { logging }: PreviewOptions): Promise { const startServerTime = performance.now(); - const base = config.buildOptions.site ? new URL(config.buildOptions.site).pathname + '/' : '/'; + const base = config.buildOptions.site ? new URL(config.buildOptions.site).pathname : '/'; // Create the preview server, send static files out of the `dist/` directory. const server = http.createServer((req, res) => {