From 5f619c769a15557571a6a980f690564ba6c67157 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Thu, 11 Sep 2025 16:49:18 -0500 Subject: [PATCH] Fix esbuild target --- src/lib/build/index.ts | 4 ++-- src/pages/ProjectView.tsx | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/lib/build/index.ts b/src/lib/build/index.ts index 343a9059..d456dd24 100644 --- a/src/lib/build/index.ts +++ b/src/lib/build/index.ts @@ -17,7 +17,7 @@ export async function buildProject( ): Promise> { const esbuild = await getEsbuild(); - const { fs, projectPath, domParser, target } = options; + const { fs, projectPath, domParser, target = "esnext" } = options; const indexHtmlText = await fs.readFile( `${projectPath}/index.html`, @@ -43,7 +43,7 @@ export async function buildProject( bundle: true, write: false, format: "esm", - target: target ?? "esnext", + target, outdir: "/", jsx: "automatic", plugins: [ diff --git a/src/pages/ProjectView.tsx b/src/pages/ProjectView.tsx index 7a7a3381..c23332a0 100644 --- a/src/pages/ProjectView.tsx +++ b/src/pages/ProjectView.tsx @@ -92,7 +92,6 @@ export function ProjectView() { fs: browserFS, projectPath: `/projects/${project.id}`, domParser: new DOMParser(), - target: "esnext", }); console.log(dist);