You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 26, 2019. It is now read-only.
Copy file name to clipboardExpand all lines: packages/react-scripts/template/README.md
+5-2Lines changed: 5 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -980,17 +980,20 @@ these defined as well. Consult their documentation how to do this. For example,
980
980
981
981
#### Expanding Environment Variables In `.env`
982
982
983
-
>Note: this feature is available with `react-scripts@1.0.18` and higher.
983
+
>Note: this feature is available with `react-scripts@1.1.0` and higher.
984
984
985
-
Expand variables already on your machine for use in your .env file (using [dotenv-expand](https://github.com/motdotla/dotenv-expand)). See [#2223](https://github.com/facebookincubator/create-react-app/issues/2223).
985
+
Expand variables already on your machine for use in your `.env` file (using [dotenv-expand](https://github.com/motdotla/dotenv-expand)).
986
986
987
987
For example, to get the environment variable `npm_package_version`:
988
+
988
989
```
989
990
REACT_APP_VERSION=$npm_package_version
990
991
# also works:
991
992
# REACT_APP_VERSION=${npm_package_version}
992
993
```
994
+
993
995
Or expand variables local to the current `.env` file:
0 commit comments