cra-runtime-environment-variables
cra-runtime-environment-variables copied to clipboard
Guide: Runtime environment variables within Create React App
There might be issues with specifying variables on the window object. A hypothetical scenario: Auth should be required/not required in specific environments. Consider an env-variable requiresAuth: boolean. If specified in...
In the final stage of the `Dockerfile` it says ``` WORKDIR /usr/share/nginx/html COPY ./env.sh . COPY .env . RUN chmod +x env.sh ``` and in the `nginx.conf` that folder is...
First of all, the idea is very smart. Really enjoyed reading it. I have a small question though regarding an `env-config.js`. Why did you prefer this solution over Nginx SSI...
The dev version works perfectly, with and without Docker. But the prod version throws an error I can't seem to resolve. `/bin/bash: /usr/share/nginx/html/env.sh: No such file or directory` I've verified...
Add new line at the end of env.sh LF Could fix #23 ?
As env-config.js able to be retrieve from browser when we access the url. So if we have sensitive information, it will causing a lot of issue on the FE side.
Hi, thanks for providing this article and gitrepo. I implemented your idea and works using Docker. I was able to dynamic change the API_URL using the `-e` flag for `docker...