# EnvironmentOptions

Environment variables options.

- Source: [`aws-lambda/lib/function.ts`](https://github.com/aws/aws-cdk/blob/v2.274.0/packages/aws-cdk-lib/aws-lambda/lib/function.ts#L1827)
- Type last changed: v2.72.0 · 29 Mar 2023

## Example

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_lambda as lambda } from 'aws-cdk-lib';
const environmentOptions: lambda.EnvironmentOptions = {
  removeInEdge: false,
};
```

## Properties

- `removeInEdge`: boolean — When used in Lambda@Edge via edgeArn() API, these environment variables will be removed.

  **Default:** false - using the function in Lambda@Edge will throw

  If not set, an error will be thrown.
