• Determines the numeric variation of a feature flag for a context, along with information about how it was calculated.

    The reason property of the result will also be included in analytics events, if you are capturing detailed event data for this flag.

    If the flag variation does not have a numeric value, defaultValue is returned. The reason will indicate an error of the type WRONG_KIND in this case.

    For more information, see the SDK reference guide.

    Parameters

    • key: string

      The unique key of the feature flag.

    • defaultValue: number

      The default value of the flag, to be used if the value is not available from LaunchDarkly.

    Returns LDEvaluationDetailTyped<number>

    The result (as an LDEvaluationDetailTyped).

Generated using TypeDoc