FeatureFlagDefinition
FeatureFlagDefinition
Definition for a feature flag, including its key, description, identify function, and decide function. The identify function is used to determine the entities that will be evaluated against the feature flag, while the decide function contains the logic for determining the outcome of the flag based on those entities.
Property | Type | Value | Description |
---|---|---|---|
decide | DecideFunction<Entity, R> | N/A | Function to decide the outcome of the feature flag. This function receives the identified entities and should return the result of the decision. |
description | string | N/A | Optional description of the feature flag. This can be used for documentation or debugging purposes. |
disableAnalytics | boolean | N/A | Whether to disable analytics tracking for this flag. Default: false |
identify | IdentifyFunction<Entity> | N/A | Optional flag to enable integration with an external flag provider. If true, the flag will use the global flag provider to determine its state. Default: false |
key | string | N/A | Unique key for the feature flag. Should be a string that identifies the flag. |