configuring env files for staging, development and other phases is quite easy.
create .env.staging .env.prodution and modify your package.json file in this way
"dev": "vite --mode staging", "production": "vite --mode production", "build": "vite build --mode production",