Replies: 1 comment 1 reply
-
That is because we are no longer directly using vite, but we are using vinxi to set vite up. Our configuration is no longer a single object containing a single server, it is containing "routes" that lead to different server configurations that can deliver static data, client bundles, server rendered pages and user middlewares by default. This is currently being discussed in #1279 (comment) - but there's no eta on when this is being fixed yet. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In pre-beta2, we can still use this https://vitejs.dev/config/#conditional-config where
defineConfig
can accept a function that hasmode
that determine development or production.However in beta-2, we can no longer do it. Seems like an obvious enough requirement to change certain configurations depending on dev or prod build. How can I still do that in beta2?
Couple of examples in my config file:
import { loadEnv } from 'vite'
andloadEnv(mode, ...)
function requires to pass in the modedevelopment
orproduction
mode === 'production'
Beta Was this translation helpful? Give feedback.
All reactions