Skip to content

Commit e9852e4

Browse files
authored
feat!: remove flag evaluation options from the provider interface (#185)
Closes #183 Signed-off-by: Michael Beemer <[email protected]>
1 parent ea36afb commit e9852e4

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@
44
[![codecov](https://codecov.io/gh/open-feature/node-sdk/branch/main/graph/badge.svg?token=3DC5XOEHMY)](https://codecov.io/gh/open-feature/node-sdk)
55
[![npm version](https://badge.fury.io/js/@openfeature%2Fnodejs-sdk.svg)](https://badge.fury.io/js/@openfeature%2Fnodejs-sdk)
66
[![Known Vulnerabilities](https://snyk.io/test/github/open-feature/node-sdk/badge.svg)](https://snyk.io/test/github/open-feature/node-sdk)
7+
[![Specification](https://img.shields.io/static/v1?label=Specification&message=v0.4.0&color=yellow)](https://github.com/open-feature/spec/tree/v0.4.0)
78

89
This is the NodeJS implementation of [OpenFeature](https://openfeature.dev), a vendor-agnostic abstraction library for evaluating feature flags.
910

10-
We support multiple data types for flags (numbers, strings, booleans, objects) as well as hooks, which can alter the lifecycle of a flag evaluation.
11+
We support multiple data types for flags (numbers, strings, booleans, objects) as well as hooks, which can alter the lifecycle of a flag evaluation.
1112

1213
This library is intended to be used in server-side contexts and has not been evaluated for use in mobile devices.
1314

src/types.ts

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,7 @@ export interface Provider extends Pick<Partial<EvaluationLifeCycle>, 'hooks'> {
118118
resolveBooleanEvaluation(
119119
flagKey: string,
120120
defaultValue: boolean,
121-
context: EvaluationContext,
122-
options: FlagEvaluationOptions | undefined
121+
context: EvaluationContext
123122
): Promise<ResolutionDetails<boolean>>;
124123

125124
/**
@@ -128,8 +127,7 @@ export interface Provider extends Pick<Partial<EvaluationLifeCycle>, 'hooks'> {
128127
resolveStringEvaluation(
129128
flagKey: string,
130129
defaultValue: string,
131-
context: EvaluationContext,
132-
options: FlagEvaluationOptions | undefined
130+
context: EvaluationContext
133131
): Promise<ResolutionDetails<string>>;
134132

135133
/**
@@ -138,8 +136,7 @@ export interface Provider extends Pick<Partial<EvaluationLifeCycle>, 'hooks'> {
138136
resolveNumberEvaluation(
139137
flagKey: string,
140138
defaultValue: number,
141-
context: EvaluationContext,
142-
options: FlagEvaluationOptions | undefined
139+
context: EvaluationContext
143140
): Promise<ResolutionDetails<number>>;
144141

145142
/**
@@ -148,8 +145,7 @@ export interface Provider extends Pick<Partial<EvaluationLifeCycle>, 'hooks'> {
148145
resolveObjectEvaluation<U extends object>(
149146
flagKey: string,
150147
defaultValue: U,
151-
context: EvaluationContext,
152-
options: FlagEvaluationOptions | undefined
148+
context: EvaluationContext
153149
): Promise<ResolutionDetails<U>>;
154150
}
155151

0 commit comments

Comments
 (0)