From 2ddf14d2b590a330099b1a2d28dae558ec88c8de Mon Sep 17 00:00:00 2001 From: John Colvin Date: Thu, 17 Oct 2024 15:55:07 +0000 Subject: [PATCH] cleanup: Move global var into function scope in vite cfg --- .../Bts.DataStreamWebApp.Client/vite.config.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/DataStreamSuite/Bts.DataStreamWebApp.Client/vite.config.js b/src/DataStreamSuite/Bts.DataStreamWebApp.Client/vite.config.js index 2667d8d44..905d521cd 100644 --- a/src/DataStreamSuite/Bts.DataStreamWebApp.Client/vite.config.js +++ b/src/DataStreamSuite/Bts.DataStreamWebApp.Client/vite.config.js @@ -29,13 +29,12 @@ if (!fs.existsSync(certFilePath) || !fs.existsSync(keyFilePath)) { } } -const target = env.ASPNETCORE_HTTPS_PORT - ? `https://localhost:${env.ASPNETCORE_HTTPS_PORT}` - : env.ASPNETCORE_URLS - ? env.ASPNETCORE_URLS.split(';')[0] - : 'https://localhost:8443'; - export default defineConfig(({ $$command, mode, $$isSsrBuild, $$isPreview }) => { + const target = env.ASPNETCORE_HTTPS_PORT + ? `https://localhost:${env.ASPNETCORE_HTTPS_PORT}` + : env.ASPNETCORE_URLS + ? env.ASPNETCORE_URLS.split(';')[0] + : 'https://localhost:8443'; return { plugins: [plugin()], resolve: {