mirror of
https://github.com/angular/angular.git
synced 2026-11-23 07:05:14 -05:00
docs: warn against storing secrets in environment files
Add a CRITICAL callout warning that files in `src/environments/` ship to the client and should not hold secrets like API keys.
This commit is contained in:
@@ -99,6 +99,8 @@ export const environment = {
|
||||
};
|
||||
```
|
||||
|
||||
CRITICAL: Files in `src/environments/` are bundled into your client-side application and visible to anyone who loads the page. Never store secrets such as API keys here. Use a server-side proxy or a secrets manager instead.
|
||||
|
||||
You can add target-specific configuration files, such as `environment.development.ts`.
|
||||
The following content sets default values for the development build target:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user