nx-vite-env-repro
Repro instructions are as follows.
Development
cd packages/my-app
npm run dev
--> App shows "VITE_FOOBAR = development"
Production without Nx
cd packages/my-app
npm run build
npm run preview
--> App shows "VITE_FOOBAR = production"
Production with Nx
npx nx run my-app:build
cd packages/my-app
npm run preview
--> App shows "VITE_FOOBAR = development"