UNPKG

@devcycle/nestjs-server-sdk

Version:

The DevCycle NestJS Server SDK used for feature management.

12 lines (11 loc) 601 B
import { DevCycleClient, DevCycleUser } from '@devcycle/nodejs-server-sdk'; import { InferredVariableType, VariableDefinitions, VariableKey } from '@devcycle/types'; import { ClsService } from 'nestjs-cls'; export declare class DevCycleService { private readonly devcycleClient; private readonly cls; constructor(devcycleClient: DevCycleClient, cls: ClsService); getUser(): DevCycleUser; isEnabled(key: VariableKey): boolean; variableValue<K extends VariableKey, ValueType extends VariableDefinitions[K]>(key: K, defaultValue: ValueType): InferredVariableType<K, ValueType>; }