Skip to content

@sourceloop/feature-toggle / Exports / FeatureHandlerService

Class: FeatureHandlerService

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new FeatureHandlerService(getHandlers)

Parameters

Name Type
getHandlers Getter<FeatureHandler[]>

Defined in

packages/feature-toggle/src/services/feature-handler-service.ts:12

Properties

getHandlers

Private getHandlers: Getter<FeatureHandler[]>

Defined in

packages/feature-toggle/src/services/feature-handler-service.ts:14

Methods

findHandler

findHandler(handlerName): Promise<undefined | FeatureHandler>

Parameters

Name Type
handlerName string

Returns

Promise<undefined | FeatureHandler>

Defined in

packages/feature-toggle/src/services/feature-handler-service.ts:17


handle

handle(featureMetadata, currentUser): Promise<boolean>

Parameters

Name Type
featureMetadata FeatureFlagMetadata
currentUser IAuthUserWithDisabledFeat

Returns

Promise<boolean>

Defined in

packages/feature-toggle/src/services/feature-handler-service.ts:22