• Determines the json 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.

    This version may be favored in TypeScript versus variation because it returns an unknown type instead of any. unknown will require a cast before usage.

    For more information, see the SDK reference guide.

    Parameters

    • key: string

      The unique key of the feature flag.

    • defaultValue: unknown

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

    Returns LDEvaluationDetailTyped<unknown>

    If you provided a callback, then nothing. Otherwise, a Promise which will be resolved with the result (as anLDEvaluationDetailTyped).

Generated using TypeDoc