From 96d931ad3633be5e4c3ab1d8fbc25460fe90c476 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B2an?= Date: Fri, 27 Sep 2024 23:34:06 +0100 Subject: [PATCH] feat(esbuild): make it possible to set `keepNames` to false via TSX_ESBUILD_KEEP_NAMES --- src/utils/transform/get-esbuild-options.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils/transform/get-esbuild-options.ts b/src/utils/transform/get-esbuild-options.ts index a9d6d44c4..2fc0fa22a 100644 --- a/src/utils/transform/get-esbuild-options.ts +++ b/src/utils/transform/get-esbuild-options.ts @@ -39,7 +39,7 @@ export const cacheConfig = { * esbuild renames variables even if minification is not enabled * https://esbuild.github.io/try/#dAAwLjE5LjUAAGNvbnN0IGEgPSAxOwooZnVuY3Rpb24gYSgpIHt9KTs */ - keepNames: true, + keepNames: process.env.TSX_ESBUILD_KEEP_NAMES !== 'false', }; export const patchOptions = (