UNPKG

featurehub-repository

Version:

Core package of API that exposes FeatureHub feature flags, values and configuration to client applications written in Typescript or Javascript.

22 lines (21 loc) 783 B
import { FeatureValueType } from './models/models'; import { ClientContext } from './client_context'; export interface FeatureListener { (featureChanged: FeatureStateHolder): void; } export interface FeatureStateHolder { getKey(): string | undefined; getString(): string | undefined; getBoolean(): boolean | undefined; getFlag(): boolean | undefined; getNumber(): number | undefined; getRawJson(): string | undefined; isSet(): boolean; isLocked(): boolean | undefined; isEnabled(): boolean; addListener(listener: FeatureListener): void; triggerListeners(feature?: FeatureStateHolder): void; getVersion(): number | undefined; getType(): FeatureValueType | undefined; withContext(param: ClientContext): FeatureStateHolder; }