We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.env
X = "1"
.env.local
X = 2
npm run dev
X = "2"
System: OS: Windows 10 10.0.19045 CPU: (16) x64 Intel(R) Core(TM) i7-10700 CPU @ 2.90GHz Memory: 5.94 GB / 31.87 GB Binaries: Node: 20.17.0 - C:\Program Files\nodejs\node.EXE Yarn: 4.5.0 - C:\Program Files\nodejs\yarn.CMD npm: 10.8.2 - C:\Program Files\nodejs\npm.CMD Browsers: Edge: Chromium (127.0.2651.74) Internet Explorer: 11.0.19041.4355 npmPackages: @remix-run/dev: ^2.12.1 => 2.12.1 @remix-run/node: ^2.12.1 => 2.12.1 @remix-run/react: ^2.12.1 => 2.12.1 @remix-run/serve: ^2.12.1 => 2.12.1 vite: ^5.1.0 => 5.4.0
npm
In development (remix vite:dev), after editing .env files, the app re-renders or reloads with the new environment variables
remix vite:dev
The app sees the old variables, even after full page reloads.
The text was updated successfully, but these errors were encountered:
Just tested. It seems for the variables already exist, they won't be reloaded. However, when we set a new variable, it is loaded correctly.
After checking how vite handles .env, I found it's an expected behavior from package dotenv-expand.
dotenv-expand
Sorry, something went wrong.
No branches or pull requests
Reproduction
X = "1"
is rendered on screen.env.local
toX = 2
and save (Also works on.env
, but StackBlitz does not persist.env
files so using.env.local
for demo)X = "1"
npm run dev
)X = "2"
is renderedSystem Info
Used Package Manager
npm
Expected Behavior
In development (
remix vite:dev
), after editing.env
files, the app re-renders or reloads with the new environment variablesActual Behavior
The app sees the old variables, even after full page reloads.
The text was updated successfully, but these errors were encountered: