@syntrologie/runtime-sdk 2.8.0-canary.43 → 2.8.0-canary.44
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/dist/{chunk-HKSVSKPN.js → chunk-OC3E47S2.js} +18 -12
- package/dist/chunk-OC3E47S2.js.map +7 -0
- package/dist/index.js +1 -1
- package/dist/react.js +1 -1
- package/dist/smart-canvas.esm.js +8 -8
- package/dist/smart-canvas.esm.js.map +2 -2
- package/dist/smart-canvas.js +18 -11
- package/dist/smart-canvas.js.map +2 -2
- package/dist/smart-canvas.min.js +7 -7
- package/dist/smart-canvas.min.js.map +2 -2
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
- package/dist/chunk-HKSVSKPN.js.map +0 -7
|
@@ -3456,7 +3456,7 @@ function getAntiFlickerSnippet(config = {}) {
|
|
|
3456
3456
|
}
|
|
3457
3457
|
|
|
3458
3458
|
// src/version.ts
|
|
3459
|
-
var SDK_VERSION = "2.8.0-canary.
|
|
3459
|
+
var SDK_VERSION = "2.8.0-canary.44";
|
|
3460
3460
|
|
|
3461
3461
|
// src/types.ts
|
|
3462
3462
|
var SDK_SCHEMA_VERSION = "2.0";
|
|
@@ -3607,12 +3607,14 @@ function getCachedConfig(sdkVersion) {
|
|
|
3607
3607
|
var resolveConfigUri = ({
|
|
3608
3608
|
configUri,
|
|
3609
3609
|
experiments,
|
|
3610
|
-
featureKey
|
|
3610
|
+
featureKey
|
|
3611
3611
|
}) => {
|
|
3612
3612
|
var _a2;
|
|
3613
3613
|
if (configUri) return configUri;
|
|
3614
|
-
|
|
3615
|
-
|
|
3614
|
+
if (featureKey) {
|
|
3615
|
+
const fromFeature = (_a2 = experiments == null ? void 0 : experiments.getFeatureValue) == null ? void 0 : _a2.call(experiments, featureKey, null);
|
|
3616
|
+
if (fromFeature) return fromFeature;
|
|
3617
|
+
}
|
|
3616
3618
|
return void 0;
|
|
3617
3619
|
};
|
|
3618
3620
|
function getVariantFlagKeys(experiments, manifestKey, variantFlagPrefix) {
|
|
@@ -3638,7 +3640,7 @@ var createCanvasConfigFetcher = ({
|
|
|
3638
3640
|
experiments,
|
|
3639
3641
|
featureKey,
|
|
3640
3642
|
credentials,
|
|
3641
|
-
configFeatureKey
|
|
3643
|
+
configFeatureKey,
|
|
3642
3644
|
manifestKey,
|
|
3643
3645
|
variantFlagPrefix,
|
|
3644
3646
|
sdkVersion
|
|
@@ -6259,8 +6261,8 @@ function SmartCanvasApp({
|
|
|
6259
6261
|
controller,
|
|
6260
6262
|
fetcher,
|
|
6261
6263
|
configUri,
|
|
6262
|
-
configUriFeatureKey
|
|
6263
|
-
configFeatureKey
|
|
6264
|
+
configUriFeatureKey,
|
|
6265
|
+
configFeatureKey,
|
|
6264
6266
|
fetchCredentials = "include",
|
|
6265
6267
|
pollIntervalMs,
|
|
6266
6268
|
experiments,
|
|
@@ -6330,8 +6332,8 @@ function SmartCanvasAppInner({
|
|
|
6330
6332
|
controller,
|
|
6331
6333
|
fetcher,
|
|
6332
6334
|
configUri,
|
|
6333
|
-
configUriFeatureKey
|
|
6334
|
-
configFeatureKey
|
|
6335
|
+
configUriFeatureKey,
|
|
6336
|
+
configFeatureKey,
|
|
6335
6337
|
fetchCredentials = "include",
|
|
6336
6338
|
pollIntervalMs: _pollIntervalMs,
|
|
6337
6339
|
experiments,
|
|
@@ -11608,9 +11610,8 @@ var ExperimentsFetcher = class {
|
|
|
11608
11610
|
__publicField(this, "featureKey");
|
|
11609
11611
|
__publicField(this, "manifestKey");
|
|
11610
11612
|
__publicField(this, "variantFlagPrefix");
|
|
11611
|
-
var _a2;
|
|
11612
11613
|
this.client = options.client;
|
|
11613
|
-
this.featureKey =
|
|
11614
|
+
this.featureKey = options.featureKey;
|
|
11614
11615
|
this.manifestKey = options.manifestKey;
|
|
11615
11616
|
this.variantFlagPrefix = options.variantFlagPrefix;
|
|
11616
11617
|
}
|
|
@@ -11639,6 +11640,11 @@ var ExperimentsFetcher = class {
|
|
|
11639
11640
|
};
|
|
11640
11641
|
}
|
|
11641
11642
|
}
|
|
11643
|
+
if (!this.featureKey) {
|
|
11644
|
+
throw new Error(
|
|
11645
|
+
"[SmartCanvas] No featureKey configured and no variant flags found. Ensure at least one config feature flag exists in your experiment platform."
|
|
11646
|
+
);
|
|
11647
|
+
}
|
|
11642
11648
|
const config = (_b = (_a2 = this.client).getFeatureValue) == null ? void 0 : _b.call(_a2, this.featureKey, null);
|
|
11643
11649
|
if (!config || typeof config !== "object") {
|
|
11644
11650
|
throw new Error(
|
|
@@ -12237,4 +12243,4 @@ export {
|
|
|
12237
12243
|
encodeToken,
|
|
12238
12244
|
Syntro
|
|
12239
12245
|
};
|
|
12240
|
-
//# sourceMappingURL=chunk-
|
|
12246
|
+
//# sourceMappingURL=chunk-OC3E47S2.js.map
|