Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions packages/sdk/akamai-base/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,20 @@
import {
init as initEdge,
LDClient,
LDContext,
LDMultiKindContext,
LDSingleKindContext,
LDOptions,
EdgeProvider,
EdgeFeatureStore,
} from '@launchdarkly/akamai-edgeworker-sdk-common';
import { BasicLogger } from '@launchdarkly/js-server-sdk-common';

type AkamaiLDClientParams = {
export * from '@launchdarkly/akamai-edgeworker-sdk-common';

export type AkamaiLDClientParams = {
sdkKey: string;
options?: LDOptions;
featureStoreProvider: EdgeProvider;
};

export type { LDClient, LDContext, LDMultiKindContext, LDSingleKindContext, EdgeProvider };

/**
* Initialize Launchdarkly client using Akamai's Edge KV as a feature store
* @param params ClientWithEdgeKVParams
Expand Down
9 changes: 3 additions & 6 deletions packages/sdk/akamai-edgekv/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,24 +12,21 @@
import {
init as initEdge,
LDClient,
LDContext,
LDMultiKindContext,
LDSingleKindContext,
LDOptions,
EdgeFeatureStore,
} from '@launchdarkly/akamai-edgeworker-sdk-common';
import { BasicLogger } from '@launchdarkly/js-server-sdk-common';
import EdgeKVProvider from './edgekv/edgeKVProvider';

type AkamaiLDClientParams = {
export * from '@launchdarkly/akamai-edgeworker-sdk-common';

export type AkamaiLDClientParams = {
sdkKey: string;
options?: LDOptions;
namespace: string;
group: string;
};

export type { LDClient, LDContext, LDMultiKindContext, LDSingleKindContext };

/**
* Initialize Launchdarkly client using Akamai's Edge KV as a feature store
* @param params ClientWithEdgeKVParams
Expand Down
29 changes: 16 additions & 13 deletions packages/shared/akamai-edgeworker-sdk/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,27 +1,30 @@
import {
BasicLogger,
LDOptions,
LDContext,
LDFeatureStore,
LDMultiKindContext,
LDSingleKindContext,
LDOptions as LDOptionsCommon,
} from '@launchdarkly/js-server-sdk-common';
import { validateOptions } from './utils';
import LDClient from './api/LDClient';
import EdgePlatform from './platform';
import createPlatformInfo from './platform/info';
import type { EdgeProvider } from './featureStore';
import { EdgeFeatureStore } from './featureStore';

export { EdgeFeatureStore } from './featureStore';
/**
* The Launchdarkly Edge SDKs configuration options. Only logger is officially
* supported. sendEvents is unsupported and is only included as a beta
* preview.
*/
type LDOptions = Pick<LDOptionsCommon, 'logger' | 'sendEvents'>;

export type {
LDClient,
LDContext,
LDMultiKindContext,
LDSingleKindContext,
LDOptions,
EdgeProvider,
};
/**
* The internal options include featureStore because that's how the LDClient
* implementation expects it.
*/
type LDOptionsInternal = LDOptions & Pick<LDOptionsCommon, 'featureStore'>;

export * from '@launchdarkly/js-server-sdk-common';
export { EdgeFeatureStore, EdgeProvider, LDOptions, LDOptionsInternal };

type BaseSDKParams = {
sdkKey: string;
Expand Down