@launchdarkly/js-client-sdk-common 1.24.0 → 1.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -0
- package/dist/cjs/LDClientImpl.d.ts +19 -8
- package/dist/cjs/LDClientImpl.d.ts.map +1 -1
- package/dist/cjs/api/LDStartOptions.d.ts +19 -0
- package/dist/cjs/api/LDStartOptions.d.ts.map +1 -0
- package/dist/cjs/api/index.d.ts +1 -0
- package/dist/cjs/api/index.d.ts.map +1 -1
- package/dist/cjs/configuration/Configuration.d.ts +10 -0
- package/dist/cjs/configuration/Configuration.d.ts.map +1 -1
- package/dist/cjs/context/ensureKey.d.ts.map +1 -1
- package/dist/cjs/datasource/FDv2DataManagerBase.d.ts.map +1 -1
- package/dist/cjs/datasource/SourceFactoryProvider.d.ts.map +1 -1
- package/dist/cjs/datasource/fdv2/CacheInitializer.d.ts.map +1 -1
- package/dist/cjs/datasource/fdv2/FDv2DataSource.d.ts.map +1 -1
- package/dist/cjs/datasource/fdv2/SourceManager.d.ts +28 -10
- package/dist/cjs/datasource/fdv2/SourceManager.d.ts.map +1 -1
- package/dist/cjs/index.cjs +231 -95
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/index.d.ts +1 -1
- package/dist/cjs/index.d.ts.map +1 -1
- package/dist/cjs/storage/getOrGenerateKey.d.ts +4 -1
- package/dist/cjs/storage/getOrGenerateKey.d.ts.map +1 -1
- package/dist/cjs/storage/namespaceUtils.d.ts +3 -6
- package/dist/cjs/storage/namespaceUtils.d.ts.map +1 -1
- package/dist/esm/LDClientImpl.d.ts +19 -8
- package/dist/esm/LDClientImpl.d.ts.map +1 -1
- package/dist/esm/api/LDStartOptions.d.ts +19 -0
- package/dist/esm/api/LDStartOptions.d.ts.map +1 -0
- package/dist/esm/api/index.d.ts +1 -0
- package/dist/esm/api/index.d.ts.map +1 -1
- package/dist/esm/configuration/Configuration.d.ts +10 -0
- package/dist/esm/configuration/Configuration.d.ts.map +1 -1
- package/dist/esm/context/ensureKey.d.ts.map +1 -1
- package/dist/esm/datasource/FDv2DataManagerBase.d.ts.map +1 -1
- package/dist/esm/datasource/SourceFactoryProvider.d.ts.map +1 -1
- package/dist/esm/datasource/fdv2/CacheInitializer.d.ts.map +1 -1
- package/dist/esm/datasource/fdv2/FDv2DataSource.d.ts.map +1 -1
- package/dist/esm/datasource/fdv2/SourceManager.d.ts +28 -10
- package/dist/esm/datasource/fdv2/SourceManager.d.ts.map +1 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.mjs +231 -95
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm/storage/getOrGenerateKey.d.ts +4 -1
- package/dist/esm/storage/getOrGenerateKey.d.ts.map +1 -1
- package/dist/esm/storage/namespaceUtils.d.ts +3 -6
- package/dist/esm/storage/namespaceUtils.d.ts.map +1 -1
- package/package.json +1 -3
|
@@ -5,7 +5,10 @@ import { Platform } from '@launchdarkly/js-sdk-common';
|
|
|
5
5
|
* @param storageKey keyed storage location where the generated key should live. See {@link namespaceForGeneratedContextKey}
|
|
6
6
|
* for related exmaples of generating a storage key and usage.
|
|
7
7
|
* @param platform crypto and storage implementations for necessary operations
|
|
8
|
+
* @param legacyStorageKey optional legacy storage key to migrate from. If the key is not found
|
|
9
|
+
* under {@link storageKey} but exists under this legacy key, it will be migrated to the new
|
|
10
|
+
* location and the legacy key will be cleared.
|
|
8
11
|
* @returns the generated key
|
|
9
12
|
*/
|
|
10
|
-
export declare const getOrGenerateKey: (storageKey: string, { crypto, storage }: Platform) => Promise<string>;
|
|
13
|
+
export declare const getOrGenerateKey: (storageKey: string, { crypto, storage }: Platform, legacyStorageKey?: string) => Promise<string>;
|
|
11
14
|
//# sourceMappingURL=getOrGenerateKey.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getOrGenerateKey.d.ts","sourceRoot":"","sources":["../../src/storage/getOrGenerateKey.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAKvD
|
|
1
|
+
{"version":3,"file":"getOrGenerateKey.d.ts","sourceRoot":"","sources":["../../src/storage/getOrGenerateKey.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAKvD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gBAAgB,eACf,MAAM,uBACG,QAAQ,qBACV,MAAM,oBAuB1B,CAAC"}
|
|
@@ -6,12 +6,9 @@ export declare function concatNamespacesAndValues(parts: {
|
|
|
6
6
|
}[]): Promise<string>;
|
|
7
7
|
export declare function namespaceForEnvironment(crypto: Crypto, sdkKey: string): Promise<string>;
|
|
8
8
|
/**
|
|
9
|
-
* @deprecated
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
* feature and those were namespaced in LaunchDarkly_ContextKeys. This function can be removed
|
|
13
|
-
* when the data under the LaunchDarkly_AnonymousKeys namespace is merged with data under the
|
|
14
|
-
* LaunchDarkly_ContextKeys namespace.
|
|
9
|
+
* @deprecated Used only for migration in ensureKey. Data stored under LaunchDarkly_AnonymousKeys
|
|
10
|
+
* is now migrated to LaunchDarkly_ContextKeys on first access. This function can be removed once
|
|
11
|
+
* all clients have had the chance to run the migration.
|
|
15
12
|
*/
|
|
16
13
|
export declare function namespaceForAnonymousGeneratedContextKey(kind: string): Promise<string>;
|
|
17
14
|
export declare function namespaceForGeneratedContextKey(kind: string): Promise<string>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"namespaceUtils.d.ts","sourceRoot":"","sources":["../../src/storage/namespaceUtils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAI9D,MAAM,MAAM,SAAS,GAAG,cAAc,GAAG,eAAe,GAAG,aAAa,GAAG,cAAc,CAAC;AAW1F,wBAAsB,yB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O,CAAC,MAAM,CAAC,CAKjB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@launchdarkly/js-client-sdk-common",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.26.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/esm/index.mjs",
|
|
6
6
|
"types": "./dist/esm/index.d.ts",
|
|
@@ -58,8 +58,6 @@
|
|
|
58
58
|
"@typescript-eslint/eslint-plugin": "^6.20.0",
|
|
59
59
|
"@typescript-eslint/parser": "^6.20.0",
|
|
60
60
|
"eslint": "^8.45.0",
|
|
61
|
-
"eslint-config-airbnb-base": "^15.0.0",
|
|
62
|
-
"eslint-config-airbnb-typescript": "^17.1.0",
|
|
63
61
|
"eslint-config-prettier": "^8.8.0",
|
|
64
62
|
"eslint-plugin-import": "^2.27.5",
|
|
65
63
|
"eslint-plugin-jest": "^27.6.3",
|