method ILaunchDarklyClient.boolVariation
ILaunchDarklyClient.boolVariation(
key: string,
defaultValue: boolean
): Promise<boolean>

Evaluates a boolean flag for a context.

Parameters

key: string

The flag key

The evaluation context

defaultValue: boolean

Returned when the flag is absent or non-boolean

Return Type

Promise<boolean>

The evaluated value

Usage

import { type ILaunchDarklyClient } from "feature-flags-plugin/src/index.ts";