@flopflip/types
Advanced tools
Comparing version 2.3.3-next.0 to 2.3.3
22
index.ts
@@ -10,9 +10,16 @@ import { LDClient as TLDClient } from 'launchdarkly-js-client-sdk'; | ||
}; | ||
export enum TAdapterSubscriptionStatus { | ||
Subscribed, | ||
Unsubscribed, | ||
} | ||
export type TAdapterStatus = { | ||
isReady?: boolean; | ||
isConfigured?: boolean; | ||
subscriptionStatus: TAdapterSubscriptionStatus; | ||
}; | ||
export type TAdapterStatusChange = Partial<TAdapterStatus>; | ||
export type TFlagsChange = TFlags; | ||
export type TAdapterEventHandlers = { | ||
onFlagsStateChange: (flags: TFlags) => void; | ||
onStatusStateChange: (status: TAdapterStatus) => void; | ||
onFlagsStateChange: (flags: TFlagsChange) => void; | ||
onStatusStateChange: (status: TAdapterStatusChange) => void; | ||
}; | ||
@@ -77,2 +84,4 @@ export type TBaseAdapterArgs = { | ||
getFlag?(flagName: TFlagName): TFlagVariation | undefined; | ||
unsubscribe(): void; | ||
subscribe(): void; | ||
} | ||
@@ -94,2 +103,4 @@ export interface TLaunchDarklyAdapterInterface | ||
updateUserContext(updatedUserProps: TUser): Promise<unknown>; | ||
unsubscribe(): void; | ||
subscribe(): void; | ||
} | ||
@@ -109,2 +120,4 @@ export interface TLocalStorageAdapterInterface | ||
waitUntilConfigured(): Promise<unknown>; | ||
unsubscribe(): void; | ||
subscribe(): void; | ||
} | ||
@@ -127,2 +140,4 @@ export interface TMemoryAdapterInterface | ||
updateFlags(flags: TFlags): void; | ||
unsubscribe(): void; | ||
subscribe(): void; | ||
} | ||
@@ -141,2 +156,4 @@ export interface TSplitioAdapterInterface | ||
getIsReady(): boolean; | ||
unsubscribe(): void; | ||
subscribe(): void; | ||
} | ||
@@ -171,3 +188,2 @@ export type TAdapter = | ||
}; | ||
export type TAdapterStatusChange = { [key: string]: boolean }; | ||
export type TOnFlagsStateChangeCallback = (flags: TFlags) => void; | ||
@@ -174,0 +190,0 @@ export type TOnStatusStateChangeCallback = ( |
{ | ||
"name": "@flopflip/types", | ||
"version": "2.3.3-next.0+5402dd7", | ||
"version": "2.3.3", | ||
"description": "Type definitions for flipflop", | ||
@@ -24,3 +24,3 @@ "scripts": {}, | ||
], | ||
"gitHead": "5402dd77f19aaa6937c6ec97bd87e91906e4265d" | ||
"gitHead": "782acd2636ba0c6a2290b700338f72ec723bc2a9" | ||
} |
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
9262
212
0
0