From 4c52388e50c8a2a94b19325b3811c5caa9d3ee0c Mon Sep 17 00:00:00 2001 From: SaqibAltaf Date: Thu, 26 Sep 2024 17:47:19 +0400 Subject: [PATCH] env validation for react-vite --- apps/react-vite/vite.config.ts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/apps/react-vite/vite.config.ts b/apps/react-vite/vite.config.ts index 00b57cd6..0f2f4251 100644 --- a/apps/react-vite/vite.config.ts +++ b/apps/react-vite/vite.config.ts @@ -8,10 +8,14 @@ import { Schema, ValidateEnv } from '@julr/vite-plugin-validate-env'; export default defineConfig({ base: './', - plugins: [react(), viteTsconfigPaths(), ValidateEnv({ - VITE_APP_API_URL: Schema.string(), - VITE_APP_ENABLE_API_MOCKING: Schema.boolean(), - }),], + plugins: [ + react(), + viteTsconfigPaths(), + ValidateEnv({ + VITE_APP_API_URL: Schema.string(), + VITE_APP_ENABLE_API_MOCKING: Schema.boolean(), + }), + ], server: { port: 3000, },