@syntrologie/runtime-sdk 2.6.0-canary.7 → 2.7.0-canary.1

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.
@@ -3358,7 +3358,7 @@ function getAntiFlickerSnippet(config = {}) {
3358
3358
  }
3359
3359
 
3360
3360
  // src/version.ts
3361
- var SDK_VERSION = "2.6.0-canary.7";
3361
+ var SDK_VERSION = "2.7.0-canary.1";
3362
3362
 
3363
3363
  // src/types.ts
3364
3364
  var SDK_SCHEMA_VERSION = "2.0";
@@ -3526,9 +3526,12 @@ function getVariantFlagKeys(experiments, manifestKey, variantFlagPrefix) {
3526
3526
  if (keys && keys.length > 0) return keys;
3527
3527
  }
3528
3528
  }
3529
- if (variantFlagPrefix && experiments.getAllFeatures) {
3529
+ if (experiments.getAllFeatures) {
3530
3530
  const all = experiments.getAllFeatures();
3531
- return Object.keys(all).filter((k) => k.startsWith(variantFlagPrefix));
3531
+ if (variantFlagPrefix) {
3532
+ return Object.keys(all).filter((k) => k.startsWith(variantFlagPrefix));
3533
+ }
3534
+ return Object.keys(all);
3532
3535
  }
3533
3536
  return [];
3534
3537
  }
@@ -3550,7 +3553,7 @@ var createCanvasConfigFetcher = ({
3550
3553
  return directConfig;
3551
3554
  }
3552
3555
  }
3553
- if (experiments && (manifestKey || variantFlagPrefix)) {
3556
+ if (experiments && (manifestKey || variantFlagPrefix || experiments.getAllFeatures)) {
3554
3557
  const variantKeys = getVariantFlagKeys(experiments, manifestKey, variantFlagPrefix);
3555
3558
  if (variantKeys.length > 0) {
3556
3559
  const resolved = resolveVariantConfigs(experiments, variantKeys);
@@ -6709,7 +6712,7 @@ var GrowthBookAdapter = class {
6709
6712
  await this.gb.loadFeatures();
6710
6713
  }
6711
6714
  setAttributes(attrs) {
6712
- this.gb.setAttributes(attrs);
6715
+ this.gb.setAttributes({ ...this.gb.getAttributes(), ...attrs });
6713
6716
  }
6714
6717
  setForcedVariations(variations) {
6715
6718
  this.gb.setForcedVariations(variations);
@@ -10722,7 +10725,7 @@ var ExperimentsFetcher = class {
10722
10725
  }
10723
10726
  }
10724
10727
  }
10725
- if (this.manifestKey || this.variantFlagPrefix) {
10728
+ if (this.manifestKey || this.variantFlagPrefix || this.client.getAllFeatures) {
10726
10729
  const config2 = this.fetchMultiFlag();
10727
10730
  if (config2) {
10728
10731
  const fetchTimeMs2 = performance.now() - start;
@@ -10773,9 +10776,12 @@ var ExperimentsFetcher = class {
10773
10776
  }
10774
10777
  }
10775
10778
  }
10776
- if (this.variantFlagPrefix && this.client.getAllFeatures) {
10779
+ if (this.client.getAllFeatures) {
10777
10780
  const allFeatures = this.client.getAllFeatures();
10778
- return Object.keys(allFeatures).filter((key) => key.startsWith(this.variantFlagPrefix));
10781
+ if (this.variantFlagPrefix) {
10782
+ return Object.keys(allFeatures).filter((key) => key.startsWith(this.variantFlagPrefix));
10783
+ }
10784
+ return Object.keys(allFeatures);
10779
10785
  }
10780
10786
  return [];
10781
10787
  }
@@ -11363,4 +11369,4 @@ export {
11363
11369
  encodeToken,
11364
11370
  Syntro
11365
11371
  };
11366
- //# sourceMappingURL=chunk-XY6ECMKW.js.map
11372
+ //# sourceMappingURL=chunk-LQCEGJW5.js.map