refactor(environment): rename config keys to camelCase

Aligns environment.* shape with TypeScript convention.
Renames: api_url -> apiBaseUrl, api_key -> apiKey,
use_api_key -> useApiKey, refresh_interval -> refreshInterval,
google_map_api_key -> googleMapApiKey.

The local environment.{ts,development.ts,local.ts} files are
gitignored and have already been migrated; this commit updates
the tracked example file and the only consumer (apiInterceptor).
This commit is contained in:
2026-04-25 17:22:49 +02:00
parent c32191b37d
commit 223955eb84
2 changed files with 13 additions and 7 deletions
+1 -1
View File
@@ -7,7 +7,7 @@ export const apiInterceptor: HttpInterceptorFn = (req, next) => {
setHeaders: { setHeaders: {
...({ 'Content-Type': 'application/json', 'Accept': 'application/json' }), ...({ 'Content-Type': 'application/json', 'Accept': 'application/json' }),
}, },
url: `${environment.api_url}${req.url}` url: `${environment.apiBaseUrl}${req.url}`
}); });
return next(apiReq); return next(apiReq);
}; };
+11 -5
View File
@@ -1,8 +1,14 @@
export const environment = { export const environment = {
// Used by build system to enable dev mode optimizations
production: <boolean> false, production: <boolean> false,
api_url:<string> 'http://localhost:3200/api', // Note: Currently used via apiInterceptor. Deprecated: duplicate of apiUrl, consider removing
api_key:<string> '<YOU-API-KEY-HERE>', apiBaseUrl: <string> 'http://localhost:3200/api',
use_api_key:<boolean> true, // Reserved for API key-based authentication (not currently used, see useApiKey)
refresh_interval:<number> 30000, apiKey: <string> '<YOU-API-KEY-HERE>',
google_map_api_key:<string> '<YOUR-GOOGLE-MAP-API-KEY-HERE>' // Reserved for toggling between JWT and API key authentication (not currently used)
useApiKey: <boolean> true,
// Reserved for data polling/refresh intervals (not currently used)
refreshInterval: <number> 30000,
// Reserved for Google Maps API integration (not currently used)
googleMapApiKey: <string> '<YOUR-GOOGLE-MAP-API-KEY-HERE>'
}; };