-
Notifications
You must be signed in to change notification settings - Fork 6
/
env.js
18 lines (16 loc) · 838 Bytes
/
env.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// This file is a placeholder and does not end up inside the main bundle.
// Instead, it is transformed and output to the dist/assets directory
// alongside the main bundle. The contents of this file are replaced with
// config for the environment by Webpack during local development and by
// CodeBuild during deployment. The generated index.html requires it
// before the main bundle.
// Example generated file:
// window.env = {
// DEPLOY_ENV: ${JSON.stringify(process.env.DEPLOY_ENV)},
// APP_VERSION: ${JSON.stringify(process.env.APP_VERSION)},
// APP_SECRET: ${JSON.stringify(process.env.APP_SECRET)},
// GA_ID: ${JSON.stringify(process.env.GA_ID)}
// }
// The variables can be accessed within app code via window.env.VARIABLE_NAME
// E.g. window.env.DEPLOY_ENV
// The types of these variables are declared in src/index.ts