feat(server): Add basePath config to host from a directory (#2092)

Co-authored-by: Marvin Hagemeister <marvin@deno.com>
This commit is contained in:
Reed von Redwitz
2023-11-29 16:44:25 +00:00
committed by GitHub
co-authored by Marvin Hagemeister
parent fe792455ab
commit 9ab8651018
40 changed files with 810 additions and 28 deletions
+4 -1
View File
@@ -55,7 +55,10 @@ export async function dev(
state.config.dev = true;
state.loadSnapshot = false;
const ctx = await getServerContext(state);
await startServer(ctx.handler(), state.config.server);
await startServer(ctx.handler(), {
...state.config.server,
basePath: state.config.basePath,
});
} else {
// Legacy entry point: Back then `dev.ts` would call `main.ts` but
// this causes duplicate plugin instantiation if both `dev.ts` and