- `method`: HTTP method to be used when retrieving environment config. Default: `GET`
- `headers`: If extra headers are needed for the request, it can be set through this field.
### Example RemoteEnv Configuration
To enable dynamic environment configuration at runtime, add the `remoteEnv` property to your environment file:
```ts
export const environment = {
// ... other configurations
remoteEnv: {
url: '/getEnvConfig',
mergeStrategy: 'deepmerge'
}
} as Environment;
```
### Web Server Configuration
When using `remoteEnv` with a URL like `/getEnvConfig`, you need to configure your web server to serve the `dynamic-env.json` file with the correct content type (`application/json`). Otherwise, the application may receive HTML (e.g., your `index.html`) instead of JSON, causing configuration to fail silently.