Skip to content

Commit

Permalink
refactor: update notes
Browse files Browse the repository at this point in the history
  • Loading branch information
sozonome committed May 14, 2024
1 parent 294e5cc commit bb629ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion content/notes/expo-env-load-behavior.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ tags:
Expo has different behavior on how it loads env variables on dev server, EAS Build, and EAS Updates

- On dev server and EAS Updates, by default it will load `.env`
- On EAS Build (unless we upload `.env` to EAS Build), it's recommended to define it in `eas.json`
- On EAS Build (unless we upload `.env` to EAS Build or exclude .env* from .gitignore), it's recommended to define it in `eas.json`
- To make sure EAS Updates load the desired env:
1. Define `NODE_ENV` and `.env.${ENVIRONMENT_NAME}`. For example we want to use `.env.production`:
2. Add `--clear-cache` to make sure it load the most fresh value
Expand Down

0 comments on commit bb629ee

Please sign in to comment.