From e3c4f00905b5384af0d26f23e85e7f76072e1207 Mon Sep 17 00:00:00 2001 From: Tom Ballinger Date: Mon, 2 Sep 2024 15:23:51 -0700 Subject: [PATCH] Upgrade esbuild from 0.17 to 0.23 (#29445) Upgrade esbuild from 0.17 to 0.23. GitOrigin-RevId: 710c5b24dae0165934f9a7dcefbc14600c6b7c2b --- CHANGELOG.md | 10 ++++++++++ package.json | 4 ++-- src/bundler/index.ts | 1 + 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 370db31..7afbd4f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,16 @@ ## Unpublished +- Upgrade esbuild from 0.17 to 0.23. It's possible to use an npm override to use + a different version of esbuild if you need to stay on an older version, + although changes to the esbuild API could break this in the future. + + See + [esbuild changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md) + for the full list of changes. One standout: tsconfig.json is no longer used by + esbuild for `jsx` setting. Convex now sets it manually to + ["automatic"](https://esbuild.github.io/api/#jsx). + ## 1.15.0 - Added new command, `npx convex function-spec`, that exposes the function diff --git a/package.json b/package.json index c763212..b73bb65 100644 --- a/package.json +++ b/package.json @@ -162,7 +162,7 @@ "CLI tool dependencies are listed in devDependencies instead." ], "dependencies": { - "esbuild": "^0.17.5", + "esbuild": "0.23.0", "jwt-decode": "^3.1.2", "prettier": "3.2.5" }, @@ -224,7 +224,7 @@ "dprint": "0.46.1", "encoding": "^0.1.13", "envfile": "6.18.0", - "esbuild": "^0.17.5", + "esbuild": "0.23.0", "esbuild-plugin-external-global": "~1.0.1", "eslint": "^8.29.0", "eslint-config-prettier": "^8.5.0", diff --git a/src/bundler/index.ts b/src/bundler/index.ts index c1810d0..c6fe423 100644 --- a/src/bundler/index.ts +++ b/src/bundler/index.ts @@ -79,6 +79,7 @@ async function doEsbuild( platform: platform, format: "esm", target: "esnext", + jsx: "automatic", outdir: "out", outbase: dir, conditions: ["convex", "module"],