@kameleoon/javascript-sdk-core 2.9.0 → 2.10.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.
Files changed (205) hide show
  1. package/package.json +2 -2
  2. package/dist/cacheManager/cacheManager.d.ts +0 -38
  3. package/dist/cacheManager/cacheManager.js +0 -12
  4. package/dist/cacheManager/cacheManager.js.map +0 -1
  5. package/dist/cacheManager/index.d.ts +0 -2
  6. package/dist/cacheManager/index.js +0 -2
  7. package/dist/cacheManager/index.js.map +0 -1
  8. package/dist/cacheManager/types.d.ts +0 -14
  9. package/dist/cacheManager/types.js +0 -2
  10. package/dist/cacheManager/types.js.map +0 -1
  11. package/dist/campaignConfiguration/campaignConfiguration.d.ts +0 -71
  12. package/dist/campaignConfiguration/campaignConfiguration.js +0 -24
  13. package/dist/campaignConfiguration/campaignConfiguration.js.map +0 -1
  14. package/dist/campaignConfiguration/constants.d.ts +0 -6
  15. package/dist/campaignConfiguration/constants.js +0 -4
  16. package/dist/campaignConfiguration/constants.js.map +0 -1
  17. package/dist/campaignConfiguration/index.d.ts +0 -3
  18. package/dist/campaignConfiguration/index.js +0 -2
  19. package/dist/campaignConfiguration/index.js.map +0 -1
  20. package/dist/campaignConfiguration/types.d.ts +0 -155
  21. package/dist/campaignConfiguration/types.js +0 -2
  22. package/dist/campaignConfiguration/types.js.map +0 -1
  23. package/dist/clientSettings/clientSettings.d.ts +0 -12
  24. package/dist/clientSettings/clientSettings.js +0 -2
  25. package/dist/clientSettings/clientSettings.js.map +0 -1
  26. package/dist/clientSettings/index.d.ts +0 -2
  27. package/dist/clientSettings/index.js +0 -2
  28. package/dist/clientSettings/index.js.map +0 -1
  29. package/dist/clientSettings/types.d.ts +0 -6
  30. package/dist/clientSettings/types.js +0 -2
  31. package/dist/clientSettings/types.js.map +0 -1
  32. package/dist/constants.d.ts +0 -32
  33. package/dist/constants.js +0 -5
  34. package/dist/constants.js.map +0 -1
  35. package/dist/eventSource/constants.d.ts +0 -1
  36. package/dist/eventSource/constants.js +0 -2
  37. package/dist/eventSource/constants.js.map +0 -1
  38. package/dist/eventSource/externalEventSource.d.ts +0 -12
  39. package/dist/eventSource/externalEventSource.js +0 -2
  40. package/dist/eventSource/externalEventSource.js.map +0 -1
  41. package/dist/eventSource/index.d.ts +0 -3
  42. package/dist/eventSource/index.js +0 -2
  43. package/dist/eventSource/index.js.map +0 -1
  44. package/dist/eventSource/types.d.ts +0 -47
  45. package/dist/eventSource/types.js +0 -2
  46. package/dist/eventSource/types.js.map +0 -1
  47. package/dist/hasher/hasher.d.ts +0 -6
  48. package/dist/hasher/hasher.js +0 -7
  49. package/dist/hasher/hasher.js.map +0 -1
  50. package/dist/hasher/index.d.ts +0 -1
  51. package/dist/hasher/index.js +0 -2
  52. package/dist/hasher/index.js.map +0 -1
  53. package/dist/hasher/types.d.ts +0 -12
  54. package/dist/hasher/types.js +0 -2
  55. package/dist/hasher/types.js.map +0 -1
  56. package/dist/index.d.ts +0 -12
  57. package/dist/index.js +0 -2
  58. package/dist/index.js.map +0 -1
  59. package/dist/kameleoonClient.d.ts +0 -253
  60. package/dist/kameleoonClient.js +0 -19
  61. package/dist/kameleoonClient.js.map +0 -1
  62. package/dist/kameleoonData/browser.d.ts +0 -26
  63. package/dist/kameleoonData/browser.js +0 -18
  64. package/dist/kameleoonData/browser.js.map +0 -1
  65. package/dist/kameleoonData/conversion.d.ts +0 -23
  66. package/dist/kameleoonData/conversion.js +0 -14
  67. package/dist/kameleoonData/conversion.js.map +0 -1
  68. package/dist/kameleoonData/customData.d.ts +0 -33
  69. package/dist/kameleoonData/customData.js +0 -25
  70. package/dist/kameleoonData/customData.js.map +0 -1
  71. package/dist/kameleoonData/device.d.ts +0 -21
  72. package/dist/kameleoonData/device.js +0 -14
  73. package/dist/kameleoonData/device.js.map +0 -1
  74. package/dist/kameleoonData/index.d.ts +0 -7
  75. package/dist/kameleoonData/index.js +0 -2
  76. package/dist/kameleoonData/index.js.map +0 -1
  77. package/dist/kameleoonData/pageView.d.ts +0 -23
  78. package/dist/kameleoonData/pageView.js +0 -14
  79. package/dist/kameleoonData/pageView.js.map +0 -1
  80. package/dist/kameleoonData/types.d.ts +0 -117
  81. package/dist/kameleoonData/types.js +0 -15
  82. package/dist/kameleoonData/types.js.map +0 -1
  83. package/dist/kameleoonData/userAgent.d.ts +0 -18
  84. package/dist/kameleoonData/userAgent.js +0 -9
  85. package/dist/kameleoonData/userAgent.js.map +0 -1
  86. package/dist/kameleoonError/constants.d.ts +0 -27
  87. package/dist/kameleoonError/constants.js +0 -2
  88. package/dist/kameleoonError/constants.js.map +0 -1
  89. package/dist/kameleoonError/helpers.d.ts +0 -1
  90. package/dist/kameleoonError/helpers.js +0 -2
  91. package/dist/kameleoonError/helpers.js.map +0 -1
  92. package/dist/kameleoonError/index.d.ts +0 -3
  93. package/dist/kameleoonError/index.js +0 -2
  94. package/dist/kameleoonError/index.js.map +0 -1
  95. package/dist/kameleoonError/kameleoonError.d.ts +0 -25
  96. package/dist/kameleoonError/kameleoonError.js +0 -5
  97. package/dist/kameleoonError/kameleoonError.js.map +0 -1
  98. package/dist/kameleoonError/types.d.ts +0 -25
  99. package/dist/kameleoonError/types.js +0 -2
  100. package/dist/kameleoonError/types.js.map +0 -1
  101. package/dist/kameleoonUtils.d.ts +0 -13
  102. package/dist/kameleoonUtils.js +0 -5
  103. package/dist/kameleoonUtils.js.map +0 -1
  104. package/dist/requester/constants.d.ts +0 -17
  105. package/dist/requester/constants.js +0 -3
  106. package/dist/requester/constants.js.map +0 -1
  107. package/dist/requester/index.d.ts +0 -3
  108. package/dist/requester/index.js +0 -2
  109. package/dist/requester/index.js.map +0 -1
  110. package/dist/requester/requester.d.ts +0 -23
  111. package/dist/requester/requester.js +0 -2
  112. package/dist/requester/requester.js.map +0 -1
  113. package/dist/requester/types.d.ts +0 -100
  114. package/dist/requester/types.js +0 -2
  115. package/dist/requester/types.js.map +0 -1
  116. package/dist/storage/constants.d.ts +0 -10
  117. package/dist/storage/constants.js +0 -5
  118. package/dist/storage/constants.js.map +0 -1
  119. package/dist/storage/externalStorage.d.ts +0 -11
  120. package/dist/storage/externalStorage.js +0 -2
  121. package/dist/storage/externalStorage.js.map +0 -1
  122. package/dist/storage/index.d.ts +0 -3
  123. package/dist/storage/index.js +0 -2
  124. package/dist/storage/index.js.map +0 -1
  125. package/dist/storage/types.d.ts +0 -63
  126. package/dist/storage/types.js +0 -2
  127. package/dist/storage/types.js.map +0 -1
  128. package/dist/targeting/conditions/browserCondition.d.ts +0 -13
  129. package/dist/targeting/conditions/browserCondition.js +0 -2
  130. package/dist/targeting/conditions/browserCondition.js.map +0 -1
  131. package/dist/targeting/conditions/conditionFactory.d.ts +0 -6
  132. package/dist/targeting/conditions/conditionFactory.js +0 -2
  133. package/dist/targeting/conditions/conditionFactory.js.map +0 -1
  134. package/dist/targeting/conditions/conversionCondition.d.ts +0 -10
  135. package/dist/targeting/conditions/conversionCondition.js +0 -4
  136. package/dist/targeting/conditions/conversionCondition.js.map +0 -1
  137. package/dist/targeting/conditions/customDataCondition.d.ts +0 -14
  138. package/dist/targeting/conditions/customDataCondition.js +0 -8
  139. package/dist/targeting/conditions/customDataCondition.js.map +0 -1
  140. package/dist/targeting/conditions/deviceCondition.d.ts +0 -9
  141. package/dist/targeting/conditions/deviceCondition.js +0 -2
  142. package/dist/targeting/conditions/deviceCondition.js.map +0 -1
  143. package/dist/targeting/conditions/exclusiveExperimentCondition.d.ts +0 -7
  144. package/dist/targeting/conditions/exclusiveExperimentCondition.js +0 -2
  145. package/dist/targeting/conditions/exclusiveExperimentCondition.js.map +0 -1
  146. package/dist/targeting/conditions/index.d.ts +0 -12
  147. package/dist/targeting/conditions/index.js +0 -2
  148. package/dist/targeting/conditions/index.js.map +0 -1
  149. package/dist/targeting/conditions/pageTitleCondition.d.ts +0 -11
  150. package/dist/targeting/conditions/pageTitleCondition.js +0 -2
  151. package/dist/targeting/conditions/pageTitleCondition.js.map +0 -1
  152. package/dist/targeting/conditions/pageUrlCondition.d.ts +0 -11
  153. package/dist/targeting/conditions/pageUrlCondition.js +0 -2
  154. package/dist/targeting/conditions/pageUrlCondition.js.map +0 -1
  155. package/dist/targeting/conditions/sdkLanguageCondition.d.ts +0 -15
  156. package/dist/targeting/conditions/sdkLanguageCondition.js +0 -2
  157. package/dist/targeting/conditions/sdkLanguageCondition.js.map +0 -1
  158. package/dist/targeting/conditions/targetExperimentCondition.d.ts +0 -12
  159. package/dist/targeting/conditions/targetExperimentCondition.js +0 -2
  160. package/dist/targeting/conditions/targetExperimentCondition.js.map +0 -1
  161. package/dist/targeting/conditions/types.d.ts +0 -42
  162. package/dist/targeting/conditions/types.js +0 -2
  163. package/dist/targeting/conditions/types.js.map +0 -1
  164. package/dist/targeting/conditions/visitorCodeCondition.d.ts +0 -11
  165. package/dist/targeting/conditions/visitorCodeCondition.js +0 -2
  166. package/dist/targeting/conditions/visitorCodeCondition.js.map +0 -1
  167. package/dist/targeting/index.d.ts +0 -3
  168. package/dist/targeting/index.js +0 -2
  169. package/dist/targeting/index.js.map +0 -1
  170. package/dist/targeting/targetingNode.d.ts +0 -23
  171. package/dist/targeting/targetingNode.js +0 -2
  172. package/dist/targeting/targetingNode.js.map +0 -1
  173. package/dist/targeting/targetingTree.d.ts +0 -19
  174. package/dist/targeting/targetingTree.js +0 -35
  175. package/dist/targeting/targetingTree.js.map +0 -1
  176. package/dist/targeting/types.d.ts +0 -142
  177. package/dist/targeting/types.js +0 -2
  178. package/dist/targeting/types.js.map +0 -1
  179. package/dist/types.d.ts +0 -175
  180. package/dist/types.js +0 -42
  181. package/dist/types.js.map +0 -1
  182. package/dist/utilities/constants.d.ts +0 -2
  183. package/dist/utilities/constants.js +0 -2
  184. package/dist/utilities/constants.js.map +0 -1
  185. package/dist/utilities/index.d.ts +0 -2
  186. package/dist/utilities/index.js +0 -2
  187. package/dist/utilities/index.js.map +0 -1
  188. package/dist/utilities/types.d.ts +0 -64
  189. package/dist/utilities/types.js +0 -2
  190. package/dist/utilities/types.js.map +0 -1
  191. package/dist/utilities/utilities.d.ts +0 -27
  192. package/dist/utilities/utilities.js +0 -2
  193. package/dist/utilities/utilities.js.map +0 -1
  194. package/dist/variationConfiguration/index.d.ts +0 -2
  195. package/dist/variationConfiguration/index.js +0 -2
  196. package/dist/variationConfiguration/index.js.map +0 -1
  197. package/dist/variationConfiguration/types.d.ts +0 -28
  198. package/dist/variationConfiguration/types.js +0 -2
  199. package/dist/variationConfiguration/types.js.map +0 -1
  200. package/dist/variationConfiguration/variation.d.ts +0 -13
  201. package/dist/variationConfiguration/variation.js +0 -7
  202. package/dist/variationConfiguration/variation.js.map +0 -1
  203. package/dist/variationConfiguration/variationConfiguration.d.ts +0 -35
  204. package/dist/variationConfiguration/variationConfiguration.js +0 -66
  205. package/dist/variationConfiguration/variationConfiguration.js.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.js","names":["UpdateType","Polling","RealTime","Idle","exports","ExperimentType","CLASSIC","SERVER_SIDE","DEVELOPER","MVT","HYBRID","RuleType","PROGRESSIVE_DELIVERY","TARGETED_DELIVERY","EXPERIMENTATION","FeatureFlagSdkLanguageType","ANDROID","SWIFT","JAVA","CSHARP","NODEJS","PHP","RUBY","GO","FLUTTER","REACTJS","FeatureStatus","ACTIVATED","DEACTIVATED","SCHEDULED","CustomDataScope","Visit","Visitor","Page","ExperimentStatus","DRAFT","ACTIVE","PAUSED","STOPPED","USED_AS_PERSONALIZATION","DEVIATED"],"sources":["../../src/campaignConfiguration/types.ts"],"sourcesContent":["import { ClientSettingsType } from 'src/clientSettings';\nimport { IExternalEventSourceConstructor } from 'src/eventSource';\nimport { KameleoonData, KameleoonDataType } from 'src/kameleoonData';\nimport { Requester, GetClientConfigurationResultType } from 'src/requester';\nimport { ClientDataType, ExternalStorage, IStorage } from 'src/storage';\nimport { OfflineTracking } from 'src/storage/types';\nimport { SegmentType, TargetingDataType } from 'src/targeting';\nimport { VariableType } from 'src/types';\n\nexport type UpdateClientConfigurationParameters = {\n timeStamp?: number;\n useCache?: boolean;\n};\n\nexport type ScheduleType = {\n dateStart: string;\n dateEnd: string;\n};\n\nexport enum UpdateType {\n Polling,\n RealTime,\n Idle,\n}\n\nexport type JSONValue =\n | string\n | number\n | boolean\n | { [x: string]: JSONValue }\n | JSONValue[];\n\nexport type JSONType = Record<string | number | symbol, JSONValue> | null;\n\nexport enum ExperimentType {\n CLASSIC = 'CLASSIC',\n SERVER_SIDE = 'SERVER_SIDE',\n DEVELOPER = 'DEVELOPER',\n MVT = 'MVT',\n HYBRID = 'HYBRID',\n}\n\nexport enum RuleType {\n PROGRESSIVE_DELIVERY = 'PROGRESSIVE_DELIVERY',\n TARGETED_DELIVERY = 'TARGETED_DELIVERY',\n EXPERIMENTATION = 'EXPERIMENTATION',\n}\n\nexport enum FeatureFlagSdkLanguageType {\n ANDROID = 'ANDROID',\n SWIFT = 'SWIFT',\n JAVA = 'JAVA',\n CSHARP = 'CSHARP',\n NODEJS = 'NODEJS',\n PHP = 'PHP',\n RUBY = 'RUBY',\n GO = 'GO',\n FLUTTER = 'FLUTTER',\n REACTJS = 'REACTJS',\n}\n\nexport enum FeatureStatus {\n ACTIVATED = 'ACTIVATED',\n DEACTIVATED = 'DEACTIVATED',\n SCHEDULED = 'SCHEDULED',\n}\n\nexport enum CustomDataScope {\n Visit = 'VISIT',\n Visitor = 'VISITOR',\n Page = 'Page',\n}\n\nexport type ExperimentItemType = {\n id: string;\n name: string;\n type: ExperimentType;\n siteId: string;\n siteCode: string;\n status: ExperimentStatus;\n siteEnabled: boolean;\n variations: ExperimentVariationType[];\n deviations: DeviationType[];\n respoolTime: RespoolTimeType[];\n segment: SegmentType | null;\n};\n\nexport type ExperimentVariationType = {\n id: string;\n customJson: string;\n};\n\nexport type DeviationType = {\n variationId: string;\n value: number;\n};\n\nexport type RespoolTimeType = {\n variationId: string;\n value: number;\n};\n\nexport enum ExperimentStatus {\n DRAFT = 'DRAFT',\n ACTIVE = 'ACTIVE',\n PAUSED = 'PAUSED',\n SCHEDULED = 'SCHEDULED',\n STOPPED = 'STOPPED',\n USED_AS_PERSONALIZATION = 'USED_AS_PERSONALIZATION',\n DEVIATED = 'DEVIATED',\n}\n\nexport type FeatureFlagType = {\n id: number;\n featureKey: string;\n variations: FeatureVariationType[];\n defaultVariationKey: string;\n rules: RuleItemType[];\n};\n\nexport type FeatureVariationType = {\n key: string;\n variables: FeatureVariableType[];\n};\n\nexport type FeatureVariableType = {\n key: string;\n type: VariableType;\n value: string | number | boolean;\n};\n\nexport type RuleItemType = {\n type: RuleType;\n id: number;\n respoolTime: number | null;\n order: number;\n exposition: number;\n experimentId: number;\n variationByExposition: VariationByExpositionType[];\n segment: SegmentType | null;\n};\n\nexport type VariationByExpositionType = {\n variationKey: string;\n variationId: number | null;\n exposition: number;\n};\n\nexport type ConfigurationDataType = {\n experiments: ExperimentItemType[];\n featureFlags: FeatureFlagType[];\n configuration: ConfigurationType;\n customData: CustomDataConfigurationType[];\n};\n\nexport type CustomDataConfigurationType = {\n index: number;\n localOnly: boolean;\n scope: CustomDataScope;\n};\n\nexport type ConfigurationType = {\n realTimeUpdate: boolean;\n};\n\nexport type CampaignConfigurationType = {\n targetingData: TargetingDataType;\n configurationData: ConfigurationDataType;\n};\n\nexport type UnsentVisitorTargetingDataType = Map<\n KameleoonData | number,\n KameleoonDataType\n>;\n\nexport type UnsentTargetingDataType = {\n [visitorCode: string]: UnsentVisitorTargetingDataType | undefined;\n};\n\nexport type CampaignConfigurationParametersType = {\n settings: ClientSettingsType;\n storage: IStorage<ClientDataType>;\n requester: Requester;\n offlineTrackingStorage: ExternalStorage<OfflineTracking>;\n externalClientConfiguration?: GetClientConfigurationResultType;\n externalEventSource: IExternalEventSourceConstructor;\n targetingCleanupInterval?: number;\n};\n"],"mappings":"mPAmBY,CAAAA,UAAU,uBAAVA,CAAU,QAAV,CAAAA,CAAU,CAAVA,CAAU,CAAAC,OAAA,cAAVD,CAAU,CAAVA,CAAU,CAAAE,QAAA,e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AAA,eAAA,IAmCf,CAAAI,gBAAgB,uBAAhBA,CAAgB,QAAhB,CAAAA,CAAgB,CAAAC,KAAA,SAAhBD,CAAgB,CAAAE,MAAA,UAAhBF,CAAgB,CAAAG,MAAA,UAAhBH,CAAgB,CAAAL,SAAA,aAAhBK,CAAgB,CAAAI,OAAA,WAAhBJ,CAAgB,CAAAK,uBAAA,2BAAhBL,CAAgB,CAAAM,QAAA,YAAhBN,CAAgB,MAAA9B,OAAA,CAAA8B,gBAAA,CAAAA,gBAAA"}
@@ -1,12 +0,0 @@
1
- import { SDKConfigurationType } from '../types';
2
- import { ClientSettingsType } from './types';
3
- export interface IClientSettings {
4
- readonly settings: ClientSettingsType;
5
- }
6
- export declare class ClientSettings implements IClientSettings {
7
- private updateInterval;
8
- private environment?;
9
- private siteCode;
10
- constructor(siteCode: string, configuration?: Partial<SDKConfigurationType>);
11
- get settings(): ClientSettingsType;
12
- }
@@ -1,2 +0,0 @@
1
- "use strict";var _types=require("../types");Object.defineProperty(exports,"__esModule",{value:!0}),exports.ClientSettings=void 0;function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function _defineProperties(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(a,_toPropertyKey(c.key),c)}function _createClass(a,b,c){return b&&_defineProperties(a.prototype,b),c&&_defineProperties(a,c),Object.defineProperty(a,"prototype",{writable:!1}),a}function _defineProperty(a,b,c){return b=_toPropertyKey(b),b in a?Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0}):a[b]=c,a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"===_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!==_typeof(a)||null===a)return a;var c=a[Symbol.toPrimitive];if(c!==void 0){var d=c.call(a,b||"default");if("object"!==_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}var ClientSettings=/*#__PURE__*/function(){function a(b,c){_classCallCheck(this,a),_defineProperty(this,"updateInterval",60*_types.Milliseconds.Minute),_defineProperty(this,"environment",void 0),_defineProperty(this,"siteCode",void 0),this.siteCode=b,null!==c&&void 0!==c&&c.environment&&(this.environment=c.environment),null!==c&&void 0!==c&&c.updateInterval&&(1>c.updateInterval&&(this.updateInterval=1*_types.Milliseconds.Minute),this.updateInterval=c.updateInterval*_types.Milliseconds.Minute)}return _createClass(a,[{key:"settings",get:function get(){return{updateInterval:this.updateInterval,environment:this.environment,siteCode:this.siteCode}}}]),a}();exports.ClientSettings=ClientSettings;
2
- //# sourceMappingURL=clientSettings.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"clientSettings.js","names":["_types","require","Object","defineProperty","exports","value","ClientSettings","_typeof","a","Symbol","iterator","constructor","prototype","_classCallCheck","b","TypeError","_defineProperties","c","d","length","enumerable","configurable","writable","_toPropertyKey","key","_createClass","_defineProperty","_toPrimitive","toPrimitive","call","String","Number","siteCode","configuration","Milliseconds","Minute","environment","updateInterval","get"],"sources":["../../src/clientSettings/clientSettings.ts"],"sourcesContent":["import { Environment, Milliseconds, SDKConfigurationType } from 'src/types';\nimport { ClientSettingsType } from './types';\n\nexport interface IClientSettings {\n readonly settings: ClientSettingsType;\n}\n\nexport class ClientSettings implements IClientSettings {\n private updateInterval: number = 60 * Milliseconds.Minute;\n private environment?: Environment;\n private siteCode: string;\n\n constructor(siteCode: string, configuration?: Partial<SDKConfigurationType>) {\n this.siteCode = siteCode;\n\n if (configuration?.environment) {\n this.environment = configuration.environment;\n }\n\n if (configuration?.updateInterval) {\n if (configuration.updateInterval < 1) {\n this.updateInterval = 1 * Milliseconds.Minute;\n }\n\n this.updateInterval = configuration.updateInterval * Milliseconds.Minute;\n }\n }\n\n get settings(): ClientSettingsType {\n return {\n updateInterval: this.updateInterval,\n environment: this.environment,\n siteCode: this.siteCode,\n };\n }\n}\n"],"mappings":"aAAA,IAAAA,MAAA,CAAAC,OAAA,aAA4EC,MAAA,CAAAC,cAAA,CAAAC,OAAA,eAAAC,KAAA,MAAAD,OAAA,CAAAE,cAAA,iBAAAC,QAAAC,CAAA,mCAAAD,OAAA,oBAAAE,MAAA,mBAAAA,MAAA,CAAAC,QAAA,UAAAF,CAAA,gBAAAA,CAAA,WAAAA,CAAA,SAAAA,CAAA,qBAAAC,MAAA,EAAAD,CAAA,CAAAG,WAAA,GAAAF,MAAA,EAAAD,CAAA,GAAAC,MAAA,CAAAG,SAAA,iBAAAJ,CAAA,EAAAD,OAAA,CAAAC,CAAA,WAAAK,gBAAAL,CAAA,CAAAM,CAAA,OAAAN,CAAA,YAAAM,CAAA,YAAAC,SAAA,+CAAAC,kBAAAR,CAAA,CAAAM,CAAA,UAAAG,CAAA,CAAAC,CAAA,GAAAA,CAAA,CAAAJ,CAAA,CAAAK,MAAA,CAAAD,CAAA,GAAAD,CAAA,CAAAH,CAAA,CAAAI,CAAA,EAAAD,CAAA,CAAAG,UAAA,CAAAH,CAAA,CAAAG,UAAA,KAAAH,CAAA,CAAAI,YAAA,cAAAJ,CAAA,GAAAA,CAAA,CAAAK,QAAA,KAAApB,MAAA,CAAAC,cAAA,CAAAK,CAAA,CAAAe,cAAA,CAAAN,CAAA,CAAAO,GAAA,EAAAP,CAAA,WAAAQ,aAAAjB,CAAA,CAAAM,CAAA,CAAAG,CAAA,SAAAH,CAAA,EAAAE,iBAAA,CAAAR,CAAA,CAAAI,SAAA,CAAAE,CAAA,EAAAG,CAAA,EAAAD,iBAAA,CAAAR,CAAA,CAAAS,CAAA,EAAAf,MAAA,CAAAC,cAAA,CAAAK,CAAA,cAAAc,QAAA,MAAAd,CAAA,UAAAkB,gBAAAlB,CAAA,CAAAM,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,CAACI,cAAc,CAAGH,mBAAY,CAACC,MAAM,CAE5E,CAAC,OAAAV,YAAA,CAAAjB,CAAA,GAAAgB,GAAA,YAAAc,GAAA,CAED,SAAAA,IAAA,CAAmC,CACjC,MAAO,CACLD,cAAc,CAAE,IAAI,CAACA,cAAc,CACnCD,WAAW,CAAE,IAAI,CAACA,WAAW,CAC7BJ,QAAQ,CAAE,IAAI,CAACA,QACjB,CACF,CAAC,IAAAxB,CAAA,IAAAJ,OAAA,CAAAE,cAAA,CAAAA,cAAA"}
@@ -1,2 +0,0 @@
1
- export { ClientSettings } from './clientSettings';
2
- export { ClientSettingsType } from './types';
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),Object.defineProperty(exports,"ClientSettings",{enumerable:!0,get:function get(){return _clientSettings.ClientSettings}}),Object.defineProperty(exports,"ClientSettingsType",{enumerable:!0,get:function get(){return _types.ClientSettingsType}});var _clientSettings=require("./clientSettings"),_types=require("./types");
2
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/clientSettings/index.ts"],"sourcesContent":["export { ClientSettings } from './clientSettings';\nexport { ClientSettingsType } from './types';\n"],"mappings":""}
@@ -1,6 +0,0 @@
1
- import { Environment } from '../types';
2
- export type ClientSettingsType = {
3
- updateInterval: number;
4
- environment?: Environment;
5
- siteCode: string;
6
- };
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});
2
- //# sourceMappingURL=types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.js","names":[],"sources":["../../src/clientSettings/types.ts"],"sourcesContent":["import { Environment } from 'src/types';\n\nexport type ClientSettingsType = {\n updateInterval: number;\n environment?: Environment;\n siteCode: string;\n};\n"],"mappings":""}
@@ -1,32 +0,0 @@
1
- export declare const UNALLOCATED_VARIATION_ID = 0;
2
- export declare const OFF_VARIATION_KEY = "off";
3
- export declare const KAMELEOON_COOKIE_KEY = "kameleoonVisitorCode";
4
- export declare const VISITOR_CODE_LENGTH = 16;
5
- export declare const CACHE_CLEANUP_TIMEOUT = 10;
6
- export declare const CACHE_ITEM_LIFETIME = 5;
7
- export declare enum Cookie {
8
- PairsDelimiter = "; ",
9
- KeyValueDelimiter = "=",
10
- MaxAge = "Max-Age",
11
- Path = "Path",
12
- Domain = "Domain"
13
- }
14
- /**
15
- * @readonly
16
- * @enum {string} an Enum of all the possible Kameleoon SDK types
17
- * */
18
- export declare enum SdkLanguageType {
19
- ANDROID = "ANDROID",
20
- IOS = "IOS",
21
- JAVA = "JAVA",
22
- CSHARP = "CSHARP",
23
- NODEJS = "NODEJS",
24
- PHP = "PHP",
25
- RUBY = "RUBY",
26
- GO = "GO",
27
- FLUTTER = "FLUTTER",
28
- REACT = "REACT",
29
- PYTHON = "PYTHON",
30
- JAVASCRIPT = "JAVASCRIPT",
31
- RUST = "RUST"
32
- }
package/dist/constants.js DELETED
@@ -1,5 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.VISITOR_CODE_LENGTH=exports.UNALLOCATED_VARIATION_ID=exports.SdkLanguageType=exports.OFF_VARIATION_KEY=exports.KAMELEOON_COOKIE_KEY=exports.Cookie=exports.CACHE_ITEM_LIFETIME=exports.CACHE_CLEANUP_TIMEOUT=void 0;var UNALLOCATED_VARIATION_ID=0;exports.UNALLOCATED_VARIATION_ID=0;var OFF_VARIATION_KEY="off";exports.OFF_VARIATION_KEY="off";var KAMELEOON_COOKIE_KEY="kameleoonVisitorCode";exports.KAMELEOON_COOKIE_KEY="kameleoonVisitorCode";var VISITOR_CODE_LENGTH=16;exports.VISITOR_CODE_LENGTH=16;var CACHE_CLEANUP_TIMEOUT=10;exports.CACHE_CLEANUP_TIMEOUT=10;var CACHE_ITEM_LIFETIME=5;exports.CACHE_ITEM_LIFETIME=5;var Cookie=/*#__PURE__*/function(a){return a.PairsDelimiter="; ",a.KeyValueDelimiter="=",a.MaxAge="Max-Age",a.Path="Path",a.Domain="Domain",a}({});/**
2
- * @readonly
3
- * @enum {string} an Enum of all the possible Kameleoon SDK types
4
- * */exports.Cookie=Cookie;var SdkLanguageType=/*#__PURE__*/function(a){return a.ANDROID="ANDROID",a.IOS="IOS",a.JAVA="JAVA",a.CSHARP="CSHARP",a.NODEJS="NODEJS",a.PHP="PHP",a.RUBY="RUBY",a.GO="GO",a.FLUTTER="FLUTTER",a.REACT="REACT",a.PYTHON="PYTHON",a.JAVASCRIPT="JAVASCRIPT",a.RUST="RUST",a}({});exports.SdkLanguageType=SdkLanguageType;
5
- //# sourceMappingURL=constants.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"constants.js","names":["UNALLOCATED_VARIATION_ID","exports","OFF_VARIATION_KEY","KAMELEOON_COOKIE_KEY","VISITOR_CODE_LENGTH","CACHE_CLEANUP_TIMEOUT","CACHE_ITEM_LIFETIME","Cookie","PairsDelimiter","KeyValueDelimiter","MaxAge","Path","Domain","SdkLanguageType","ANDROID","IOS","JAVA","CSHARP","NODEJS","PHP","RUBY","GO","FLUTTER","REACT","PYTHON","JAVASCRIPT","RUST"],"sources":["../src/constants.ts"],"sourcesContent":["export const UNALLOCATED_VARIATION_ID = 0;\nexport const OFF_VARIATION_KEY = 'off';\nexport const KAMELEOON_COOKIE_KEY = 'kameleoonVisitorCode';\nexport const VISITOR_CODE_LENGTH = 16;\nexport const CACHE_CLEANUP_TIMEOUT = 10;\nexport const CACHE_ITEM_LIFETIME = 5;\n\nexport enum Cookie {\n PairsDelimiter = '; ',\n KeyValueDelimiter = '=',\n MaxAge = 'Max-Age',\n Path = 'Path',\n Domain = 'Domain',\n}\n\n/**\n * @readonly\n * @enum {string} an Enum of all the possible Kameleoon SDK types\n * */\nexport enum SdkLanguageType {\n ANDROID = 'ANDROID',\n IOS = 'IOS',\n JAVA = 'JAVA',\n CSHARP = 'CSHARP',\n NODEJS = 'NODEJS',\n PHP = 'PHP',\n RUBY = 'RUBY',\n GO = 'GO',\n FL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IME_EVENT = "configuration-update-event";
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.REAL_TIME_EVENT=void 0;var REAL_TIME_EVENT="configuration-update-event";exports.REAL_TIME_EVENT="configuration-update-event";
2
- //# sourceMappingURL=constants.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"constants.js","names":["REAL_TIME_EVENT","exports"],"sources":["../../src/eventSource/constants.ts"],"sourcesContent":["export const REAL_TIME_EVENT = 'configuration-update-event';\n"],"mappings":"mGAAO,GAAM,CAAAA,eAAe,CAAG,4BAA4B,CAACC,OAAA,CAAAD,eAAA"}
@@ -1,12 +0,0 @@
1
- import { IExternalEventSourceConstructor } from './types';
2
- export interface IEventSource {
3
- open: (onEvent: (timestamp: number) => void) => void;
4
- close: () => void;
5
- }
6
- export declare class ExternalEventSource implements IEventSource {
7
- private eventSource;
8
- private siteCode;
9
- constructor(siteCode: string, externalEventSource: IExternalEventSourceConstructor);
10
- open(onEvent: (timestamp: number) => void): void;
11
- close(): void;
12
- }
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ExternalEventSource=void 0;var _requester=require("../requester"),_constants=require("../requester/constants"),_constants2=require("./constants");function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function _defineProperties(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(a,_toPropertyKey(c.key),c)}function _createClass(a,b,c){return b&&_defineProperties(a.prototype,b),c&&_defineProperties(a,c),Object.defineProperty(a,"prototype",{writable:!1}),a}function _defineProperty(a,b,c){return b=_toPropertyKey(b),b in a?Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0}):a[b]=c,a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"===_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!==_typeof(a)||null===a)return a;var c=a[Symbol.toPrimitive];if(c!==void 0){var d=c.call(a,b||"default");if("object"!==_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}var ExternalEventSource=/*#__PURE__*/function(){function a(b,c){_classCallCheck(this,a),_defineProperty(this,"eventSource",void 0),_defineProperty(this,"siteCode",void 0);var d=_requester.URL.SERVER_SENT_EVENTS+_constants.UrlQuery.Sse+b,e=c.initialize(d);this.eventSource=e,this.siteCode=b}return _createClass(a,[{key:"open",value:function open(a){this.eventSource.open({onEvent:a,siteCode:this.siteCode,eventType:_constants2.REAL_TIME_EVENT})}},{key:"close",value:function close(){this.eventSource.close()}}]),a}();exports.ExternalEventSource=ExternalEventSource;
2
- //# sourceMappingURL=externalEventSource.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"externalEventSource.js","names":["ExternalEventSource","a","siteCode","externalEventSource","_classCallCheck","_defineProperty","url","URL","SERVER_SENT_EVENTS","UrlQuery","Sse","eventSource","initialize","_createClass","key","value","open","onEvent","eventType","REAL_TIME_EVENT","close","exports"],"sources":["../../src/eventSource/externalEventSource.ts"],"sourcesContent":["import { URL } from 'src/requester';\nimport { UrlQuery } from 'src/requester/constants';\nimport { REAL_TIME_EVENT } from './constants';\nimport { IExternalEventSource, IExternalEventSourceConstructor } from './types';\n\nexport interface IEventSource {\n open: (onEvent: (timestamp: number) => void) => void;\n close: () => void;\n}\n\nexport class ExternalEventSource implements IEventSource {\n private eventSource: IExternalEventSource;\n private siteCode: string;\n\n constructor(\n siteCode: string,\n externalEventSource: IExternalEventSourceConstructor,\n ) {\n const url = URL.SERVER_SENT_EVENTS + UrlQuery.Sse + siteCode;\n const eventSource = externalEventSource.initialize(url);\n\n this.eventSource = eventSource;\n this.siteCode = siteCode;\n }\n\n public open(onEvent: (timestamp: number) => void): void {\n this.eventSource.open({\n onEvent,\n siteCode: this.siteCode,\n eventType: REAL_TIME_EVENT,\n });\n }\n\n public close(): void {\n this.eventSource.close();\n }\n}\n"],"mappings":"08CAUa,CAAAA,mBAAmB,yBAI9B,SAAAC,EACEC,CAAgB,CAChBC,CAAoD,CACpD,CAAAC,eAAA,MAAAH,CAAA,EAAAI,eAAA,4BAAAA,eAAA,4BACM,CAAAC,CAAG,CAAGC,cAAG,CAACC,kBAAkB,CAAGC,mBAAQ,CAACC,GAAG,CAAGR,CAAQ,CACtDS,CAAW,CAAGR,CAAmB,CAACS,UAAU,CAACN,CAAG,CAAC,CAEvD,IAAI,CAACK,WAAW,CAAGA,CAAW,CAC9B,IAAI,CAACT,QAAQ,CAAGA,CAClB,CAAC,OAAAW,YAAA,CAAAZ,CAAA,GAAAa,GAAA,QAAAC,KAAA,CAED,SAAAC,KAAYC,CAAoC,CAAQ,CACtD,IAAI,CAACN,WAAW,CAACK,IAAI,CAAC,CACpBC,OAAO,CAAPA,CAAO,CACPf,QAAQ,CAAE,IAAI,CAACA,QAAQ,CACvBgB,SAAS,CAAEC,2BACb,CAAC,CACH,CAAC,GAAAL,GAAA,SAAAC,KAAA,CAED,SAAAK,MAAA,CAAqB,CACnB,IAAI,CAACT,WAAW,CAACS,KAAK,EACxB,CAAC,IAAAnB,CAAA,IAAAoB,OAAA,CAAArB,mBAAA,CAAAA,mBAAA"}
@@ -1,3 +0,0 @@
1
- export { IExternalEventSourceConstructor, EventSourceOpenParametersType, IExternalEventSource, RealTimeEventType, } from './types';
2
- export { ExternalEventSource, IEventSource } from './externalEventSource';
3
- export { REAL_TIME_EVENT } from './constants';
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),Object.defineProperty(exports,"EventSourceOpenParametersType",{enumerable:!0,get:function get(){return _types.EventSourceOpenParametersType}}),Object.defineProperty(exports,"ExternalEventSource",{enumerable:!0,get:function get(){return _externalEventSource.ExternalEventSource}}),Object.defineProperty(exports,"IEventSource",{enumerable:!0,get:function get(){return _externalEventSource.IEventSource}}),Object.defineProperty(exports,"IExternalEventSource",{enumerable:!0,get:function get(){return _types.IExternalEventSource}}),Object.defineProperty(exports,"IExternalEventSourceConstructor",{enumerable:!0,get:function get(){return _types.IExternalEventSourceConstructor}}),Object.defineProperty(exports,"REAL_TIME_EVENT",{enumerable:!0,get:function get(){return _constants.REAL_TIME_EVENT}}),Object.defineProperty(exports,"RealTimeEventType",{enumerable:!0,get:function get(){return _types.RealTimeEventType}});var _types=require("./types"),_externalEventSource=require("./externalEventSource"),_constants=require("./constants");
2
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/eventSource/index.ts"],"sourcesContent":["export {\n IExternalEventSourceConstructor,\n EventSourceOpenParametersType,\n IExternalEventSource,\n RealTimeEventType,\n} from './types';\nexport { ExternalEventSource, IEventSource } from './externalEventSource';\nexport { REAL_TIME_EVENT } from './constants';\n"],"mappings":""}
@@ -1,47 +0,0 @@
1
- /**
2
- * @interface an interface of External Constructor for External Event Source which must be implemented by the wrapper constructor to initialize new `IExternalEventSource` in order to pass the necessary `url` parameter
3
- * */
4
- export interface IExternalEventSourceConstructor {
5
- /**
6
- * @method initialize - creates and instance of `IExternalEventSource` and returns it
7
- * @param {string} url - url of server sent event server which will be pasted by consumer
8
- * @returns {IExternalEventSource} an initialized instance of `IExternalEventSource`
9
- * */
10
- initialize: (url: string) => IExternalEventSource;
11
- }
12
- /**
13
- * @param {string} siteCode - site code from the event
14
- * @param {string} eventType - type of event to be listened for
15
- * @param {(timestamp: number) => void} onEvent - callback to be executed upon event if the site code from event matches the site code of EvenetSource
16
- * */
17
- export type EventSourceOpenParametersType = {
18
- siteCode: string;
19
- eventType: string;
20
- onEvent: (timestamp: number) => void;
21
- };
22
- /**
23
- * @interface an interface of External Event Source which will be used in server sent events operations
24
- * */
25
- export interface IExternalEventSource {
26
- /**
27
- * @method open - opens event source live connection
28
- * @param {(timestamp: number) => void} callback - callback function that will be executed on each obtainment of server event
29
- * */
30
- open: ({ siteCode, eventType, onEvent, }: EventSourceOpenParametersType) => void;
31
- /**
32
- * @method close - closes event source live connection
33
- * */
34
- close: () => void;
35
- }
36
- /**
37
- * @param {string} siteCode - site code from the event
38
- * @param {number} ts - timestamp of when the event has happened
39
- * */
40
- export type RealTimeEventType = {
41
- siteCode: string;
42
- ts: number;
43
- };
44
- export type CreateEventSourceParamsType = {
45
- siteCode: string;
46
- externalEventSource?: IExternalEventSourceConstructor;
47
- };
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});
2
- //# sourceMappingURL=types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.js","names":[],"sources":["../../src/eventSource/types.ts"],"sourcesContent":["/**\n * @interface an interface of External Constructor for External Event Source which must be implemented by the wrapper constructor to initialize new `IExternalEventSource` in order to pass the necessary `url` parameter\n * */\nexport interface IExternalEventSourceConstructor {\n /**\n * @method initialize - creates and instance of `IExternalEventSource` and returns it\n * @param {string} url - url of server sent event server which will be pasted by consumer\n * @returns {IExternalEventSource} an initialized instance of `IExternalEventSource`\n * */\n initialize: (url: string) => IExternalEventSource;\n}\n\n/**\n * @param {string} siteCode - site code from the event\n * @param {string} eventType - type of event to be listened for\n * @param {(timestamp: number) => void} onEvent - callback to be executed upon event if the site code from event matches the site code of EvenetSource\n * */\nexport type EventSourceOpenParametersType = {\n siteCode: string;\n eventType: string;\n onEvent: (timestamp: number) => void;\n};\n\n/**\n * @interface an interface of External Event Source which will be used in server sent events operations\n * */\nexport interface IExternalEventSource {\n /**\n * @method open - opens event source live connection\n * @param {(timestamp: number) => void} callback - callback function that will be executed on each obtainment of server event\n * */\n open: ({\n siteCode,\n eventType,\n onEvent,\n }: EventSourceOpenParametersType) => void;\n /**\n * @method close - closes event source live connection\n * */\n close: () => void;\n}\n\n/**\n * @param {string} siteCode - site code from the event\n * @param {number} ts - timestamp of when the event has happened\n * */\nexport type RealTimeEventType = {\n siteCode: string;\n ts: number;\n};\n\nexport type CreateEventSourceParamsType = {\n siteCode: string;\n externalEventSource?: IExternalEventSourceConstructor;\n};\n"],"mappings":""}
@@ -1,6 +0,0 @@
1
- import { ObtainExperimentHashDoubleParamsType, ObtainFeatureFlagHashDoubleParamsType } from './types';
2
- export declare class Hasher {
3
- static obtainExperimentHashDouble({ visitorCode, campaignId, respoolTime, }: ObtainExperimentHashDoubleParamsType): number;
4
- static obtainFeatureFlagHashDouble({ visitorCode, campaignId, respoolTime, }: ObtainFeatureFlagHashDoubleParamsType): number;
5
- static calculateHash(seed: string): number;
6
- }
@@ -1,7 +0,0 @@
1
- "use strict";var _sha=_interopRequireDefault(require("crypto-js/sha256"));Object.defineProperty(exports,"__esModule",{value:!0}),exports.Hasher=void 0;function _interopRequireDefault(a){return a&&a.__esModule?a:{default:a}}function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function _defineProperties(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(a,_toPropertyKey(c.key),c)}function _createClass(a,b,c){return b&&_defineProperties(a.prototype,b),c&&_defineProperties(a,c),Object.defineProperty(a,"prototype",{writable:!1}),a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"===_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!==_typeof(a)||null===a)return a;var c=a[Symbol.toPrimitive];if(c!==void 0){var d=c.call(a,b||"default");if("object"!==_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}var Hasher=/*#__PURE__*/function(){function a(){_classCallCheck(this,a)}return _createClass(a,null,[{key:"obtainExperimentHashDouble",value:function obtainExperimentHashDouble(a){var b=a.visitorCode,c=a.campaignId,d=a.respoolTime,e="";return d.length&&d.forEach(function(a){e+=a.value+""}),this.calculateHash(b+c+e)}},{key:"obtainFeatureFlagHashDouble",value:function obtainFeatureFlagHashDouble(a){var b=a.visitorCode,c=a.campaignId,d=a.respoolTime,e="";return d&&(e+=d+""),this.calculateHash(b+c+e)}// --- Note ---
2
- // `hashDouble` is a seeded pseudo-random number between 0 and 1
3
- // used for deciding what variation to assign
4
- // `calculateHash` algorithm is consistent between every SDK
5
- // and will always provide same pseudo-random value for the same input parameters
6
- },{key:"calculateHash",value:function calculateHash(a){var b=(0,_sha.default)(a).toString();return parseInt(b,16)/Math.pow(2,256)}}]),a}();exports.Hasher=Hasher;
7
- //# sourceMappingURL=hasher.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"hasher.js","names":["_sha","_interopRequireDefault","require","Object","defineProperty","exports","value","Hasher","a","__esModule","default","_typeof","Symbol","iterator","constructor","prototype","_classCallCheck","b","TypeError","_defineProperties","c","d","length","enumerable","configurable","writable","_toPropertyKey","key","_createClass","_toPrimitive","toPrimitive","call","String","Number","obtainExperimentHashDouble","visitorCode","campaignId","respoolTime","respoolTimeString","forEach","respoolObject","calculateHash","obtainFeatureFlagHashDouble","suffix","seed","hashDigest","sha256","toString","parseInt","Math","pow"],"sources":["../../src/hasher/hasher.ts"],"sourcesContent":["import sha256 from 'crypto-js/sha256';\nimport {\n ObtainExperimentHashDoubleParamsType,\n ObtainFeatureFlagHashDoubleParamsType,\n} from './types';\n\nexport class Hasher {\n static obtainExperimentHashDouble({\n visitorCode,\n campaignId,\n respoolTime,\n }: ObtainExperimentHashDoubleParamsType): number {\n let respoolTimeString = '';\n\n if (respoolTime.length) {\n respoolTime.forEach((respoolObject) => {\n respoolTimeString += String(respoolObject.value);\n });\n }\n\n return this.calculateHash(visitorCode + campaignId + respoolTimeString);\n }\n\n static obtainFeatureFlagHashDouble({\n visitorCode,\n campaignId,\n respoolTime,\n }: ObtainFeatureFlagHashDoubleParamsType): number {\n let suffix = '';\n\n if (respoolTime) {\n suffix += String(respoolTime);\n }\n\n return this.calculateHash(visitorCode + campaignId + suffix);\n }\n\n // --- Note ---\n // `hashDouble` is a seeded pseudo-random number between 0 and 1\n // used for deciding what variation to assign\n // `calculateHash` algorithm is consistent between every SDK\n // and will always provide same pseudo-random value for the same input parameters\n static calculateHash(seed: string): number {\n const hashDigest = sha256(seed).toString();\n\n return parseInt(hashDigest, 16) / Math.pow(2, 256);\n }\n}\n"],"mappings":"aAAA,IAAAA,IAAA,CAAAC,sBAAA,CAAAC,OAAA,sBAAsCC,MAAA,CAAAC,cAAA,CAAAC,OAAA,eAAAC,KAAA,MAAAD,OAAA,CAAAE,MAAA,iBAAAN,uBAAAO,CAAA,SAAAA,CAAA,EAAAA,CAAA,CAAAC,UAAA,CAAAD,CAAA,EAAAE,OAAA,CAAAF,CAAA,WAAAG,QAAAH,CAAA,mCAAAG,OAAA,oBAAAC,MAAA,mBAAAA,MAAA,CAAAC,QAAA,UAAAL,CAAA,gBAAAA,CAAA,WAAAA,CAAA,SAAAA,CAAA,qBAAAI,MAAA,EAAAJ,CAAA,CAAAM,WAAA,GAAAF,MAAA,EAAAJ,CAAA,GAAAI,MAAA,CAAAG,SAAA,iBAAAP,CAAA,EAAAG,OAAA,CAAAH,CAAA,WAAAQ,gBAAAR,CAAA,CAAAS,CAAA,OAAAT,CAAA,YAAAS,CAAA,YAAAC,SAAA,+CAAAC,kBAAAX,CAAA,CAAAS,CAAA,UAAAG,CAAA,CAAAC,CAAA,GAAAA,CAAA,CAAAJ,CAAA,CAAAK,MAAA,CAAAD,CAAA,GAAAD,CAAA,CAAAH,CAAA,CAAAI,CAAA,EAAAD,CAAA,CAAAG,UAAA,CAAAH,CAAA,CAAAG,UAAA,KAAAH,CAAA,CAAAI,YAAA,c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F,CAAiB,EAAWE,CAAa,CAAClC,KAAK,GACjD,CAAC,CAAC,CAGG,IAAI,CAACmC,aAAa,CAACN,CAAW,CAAGC,CAAU,CAAGE,CAAiB,CACxE,CAAC,GAAAX,GAAA,+BAAArB,KAAA,CAED,SAAAoC,4BAAAlC,CAAA,CAIkD,IAHhD,CAAA2B,CAAW,CAAA3B,CAAA,CAAX2B,WAAW,CACXC,CAAU,CAAA5B,CAAA,CAAV4B,UAAU,CACVC,CAAW,CAAA7B,CAAA,CAAX6B,WAAW,CAEPM,CAAM,CAAG,EAAE,CAMf,MAJI,CAAAN,CAAW,GACbM,CAAM,EAAWN,CAAW,GAAC,EAGxB,IAAI,CAACI,aAAa,CAACN,CAAW,CAAGC,CAAU,CAAGO,CAAM,CAC7D,CAEA;AACA;AACA;AACA;AACA;AAAA,GAAAhB,GAAA,iBAAArB,KAAA,CACA,SAAAmC,cAAqBG,CAAY,CAAU,CACzC,GAAM,CAAAC,CAAU,CAAG,GAAAC,YAAM,EAACF,CAAI,CAAC,CAACG,QAAQ,EAAE,CAE1C,MAAO,CAAAC,QAAQ,CAACH,CAAU,CAAE,EAAE,CAAC,CAAGI,IAAI,CAACC,GAAG,CAAC,CAAC,CAAE,GAAG,CACnD,CAAC,IAAA1C,CAAA,IAAAH,OAAA,CAAAE,MAAA,CAAAA,MAAA"}
@@ -1 +0,0 @@
1
- export { Hasher } from './hasher';
@@ -1,2 +0,0 @@
1
- "use strict";var _hasher=require("./hasher");Object.defineProperty(exports,"__esModule",{value:!0}),Object.defineProperty(exports,"Hasher",{enumerable:!0,get:function get(){return _hasher.Hasher}});
2
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","names":["_hasher","require","Object","defineProperty","exports","value","enumerable","get","Hasher"],"sources":["../../src/hasher/index.ts"],"sourcesContent":["export { Hasher } from './hasher';\n"],"mappings":"aAAA,IAAAA,OAAA,CAAAC,OAAA,aAAkCC,MAAA,CAAAC,cAAA,CAAAC,OAAA,eAAAC,KAAA,MAAAH,MAAA,CAAAC,cAAA,CAAAC,OAAA,WAAAE,UAAA,IAAAC,GAAA,UAAAA,IAAA,SAAAP,OAAA,CAAAQ,MAAA"}
@@ -1,12 +0,0 @@
1
- import { RespoolTimeType } from '../campaignConfiguration/types';
2
- type ObtainHashDoubleParamsType = {
3
- visitorCode: string;
4
- campaignId: string;
5
- };
6
- export type ObtainExperimentHashDoubleParamsType = ObtainHashDoubleParamsType & {
7
- respoolTime: RespoolTimeType[];
8
- };
9
- export type ObtainFeatureFlagHashDoubleParamsType = ObtainHashDoubleParamsType & {
10
- respoolTime: number | null;
11
- };
12
- export {};
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});
2
- //# sourceMappingURL=types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.js","names":[],"sources":["../../src/hasher/types.ts"],"sourcesContent":["import { RespoolTimeType } from 'src/campaignConfiguration/types';\n\ntype ObtainHashDoubleParamsType = {\n visitorCode: string;\n campaignId: string;\n};\n\nexport type ObtainExperimentHashDoubleParamsType =\n ObtainHashDoubleParamsType & {\n respoolTime: RespoolTimeType[];\n };\n\nexport type ObtainFeatureFlagHashDoubleParamsType =\n ObtainHashDoubleParamsType & {\n respoolTime: number | null;\n };\n"],"mappings":""}
package/dist/index.d.ts DELETED
@@ -1,12 +0,0 @@
1
- export { Ok, Result, Err } from 'ts-res';
2
- export { KameleoonClient as KameleoonCore, IKameleoonClient as IKameleoonCore, } from './kameleoonClient';
3
- export { KameleoonUtils as KameleoonCoreUtils } from './kameleoonUtils';
4
- export { KameleoonException, KameleoonError } from './kameleoonError';
5
- export { KameleoonStorageKey, IExternalStorage, IExternalStorageConstructor, } from './storage';
6
- export { Cookie, VISITOR_CODE_LENGTH, SdkLanguageType } from './constants';
7
- export { CLEANUP_TARGETING_DATA_INTERVAL } from './campaignConfiguration';
8
- export { JSONType } from './campaignConfiguration';
9
- export { Environment, VariableType, ExperimentType, FeatureFlagType, SDKCoreParameters, SDKConfigurationType, ExternalPackageInfoType, TrackConversionParamsType, FeatureVariableResultType, InternalSDKConfigurationType, GetFeatureFlagVariableParamsType, ServerGetVisitorCodeParametersType, ClientGetVisitorCodeParametersType, MobileGetVisitorCodeParametersType, Milliseconds, } from './types';
10
- export { CustomData, Conversion, Device, Browser, UserAgent, DeviceType, BrowserType, PageView, KameleoonData, KameleoonDataType, PageViewParametersType, ConversionParametersType, } from './kameleoonData';
11
- export { RealTimeEventType, IExternalEventSource, EventSourceOpenParametersType, IExternalEventSourceConstructor, } from './eventSource';
12
- export { Header, HttpMethod, TrackParametersType, IExternalRequestDispatcher, GetClientConfigurationResultType, } from './requester';
package/dist/index.js DELETED
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),Object.defineProperty(exports,"Browser",{enumerable:!0,get:function get(){return _kameleoonData.Browser}}),Object.defineProperty(exports,"BrowserType",{enumerable:!0,get:function get(){return _kameleoonData.BrowserType}}),Object.defineProperty(exports,"CLEANUP_TARGETING_DATA_INTERVAL",{enumerable:!0,get:function get(){return _campaignConfiguration.CLEANUP_TARGETING_DATA_INTERVAL}}),Object.defineProperty(exports,"ClientGetVisitorCodeParametersType",{enumerable:!0,get:function get(){return _types.ClientGetVisitorCodeParametersType}}),Object.defineProperty(exports,"Conversion",{enumerable:!0,get:function get(){return _kameleoonData.Conversion}}),Object.defineProperty(exports,"ConversionParametersType",{enumerable:!0,get:function get(){return _kameleoonData.ConversionParametersType}}),Object.defineProperty(exports,"Cookie",{enumerable:!0,get:function get(){return _constants.Cookie}}),Object.defineProperty(exports,"CustomData",{enumerable:!0,get:function get(){return _kameleoonData.CustomData}}),Object.defineProperty(exports,"Device",{enumerable:!0,get:function get(){return _kameleoonData.Device}}),Object.defineProperty(exports,"DeviceType",{enumerable:!0,get:function get(){return _kameleoonData.DeviceType}}),Object.defineProperty(exports,"Environment",{enumerable:!0,get:function get(){return _types.Environment}}),Object.defineProperty(exports,"Err",{enumerable:!0,get:function get(){return _tsRes.Err}}),Object.defineProperty(exports,"EventSourceOpenParametersType",{enumerable:!0,get:function get(){return _eventSource.EventSourceOpenParametersType}}),Object.defineProperty(exports,"ExperimentType",{enumerable:!0,get:function get(){return _types.ExperimentType}}),Object.defineProperty(exports,"ExternalPackageInfoType",{enumerable:!0,get:function get(){return _types.ExternalPackageInfoType}}),Object.defineProperty(exports,"FeatureFlagType",{enumerable:!0,get:function get(){return _types.FeatureFlagType}}),Object.defineProperty(exports,"FeatureVariableResultType",{enumerable:!0,get:function get(){return _types.FeatureVariableResultType}}),Object.defineProperty(exports,"GetClientConfigurationResultType",{enumerable:!0,get:function get(){return _requester.GetClientConfigurationResultType}}),Object.defineProperty(exports,"GetFeatureFlagVariableParamsType",{enumerable:!0,get:function get(){return _types.GetFeatureFlagVariableParamsType}}),Object.defineProperty(exports,"Header",{enumerable:!0,get:function get(){return _requester.Header}}),Object.defineProperty(exports,"HttpMethod",{enumerable:!0,get:function get(){return _requester.HttpMethod}}),Object.defineProperty(exports,"IExternalEventSource",{enumerable:!0,get:function get(){return _eventSource.IExternalEventSource}}),Object.defineProperty(exports,"IExternalEventSourceConstructor",{enumerable:!0,get:function get(){return _eventSource.IExternalEventSourceConstructor}}),Object.defineProperty(exports,"IExternalRequestDispatcher",{enumerable:!0,get:function get(){return _requester.IExternalRequestDispatcher}}),Object.defineProperty(exports,"IExternalStorage",{enumerable:!0,get:function get(){return _storage.IExternalStorage}}),Object.defineProperty(exports,"IExternalStorageConstructor",{enumerable:!0,get:function get(){return _storage.IExternalStorageConstructor}}),Object.defineProperty(exports,"IKameleoonCore",{enumerable:!0,get:function get(){return _kameleoonClient.IKameleoonClient}}),Object.defineProperty(exports,"InternalSDKConfigurationType",{enumerable:!0,get:function get(){return _types.InternalSDKConfigurationType}}),Object.defineProperty(exports,"JSONType",{enumerable:!0,get:function get(){return _campaignConfiguration.JSONType}}),Object.defineProperty(exports,"KameleoonCore",{enumerable:!0,get:function get(){return _kameleoonClient.KameleoonClient}}),Object.defineProperty(exports,"KameleoonCoreUtils",{enumerable:!0,get:function get(){return _kameleoonUtils.KameleoonUtils}}),Object.defineProperty(exports,"KameleoonData",{enumerable:!0,get:function get(){return _kameleoonData.KameleoonData}}),Object.defineProperty(exports,"KameleoonDataType",{enumerable:!0,get:function get(){return _kameleoonData.KameleoonDataType}}),Object.defineProperty(exports,"KameleoonError",{enumerable:!0,get:function get(){return _kameleoonError.KameleoonError}}),Object.defineProperty(exports,"KameleoonException",{enumerable:!0,get:function get(){return _kameleoonError.KameleoonException}}),Object.defineProperty(exports,"KameleoonStorageKey",{enumerable:!0,get:function get(){return _storage.KameleoonStorageKey}}),Object.defineProperty(exports,"Milliseconds",{enumerable:!0,get:function get(){return _types.Milliseconds}}),Object.defineProperty(exports,"MobileGetVisitorCodeParametersType",{enumerable:!0,get:function get(){return _types.MobileGetVisitorCodeParametersType}}),Object.defineProperty(exports,"Ok",{enumerable:!0,get:function get(){return _tsRes.Ok}}),Object.defineProperty(exports,"PageView",{enumerable:!0,get:function get(){return _kameleoonData.PageView}}),Object.defineProperty(exports,"PageViewParametersType",{enumerable:!0,get:function get(){return _kameleoonData.PageViewParametersType}}),Object.defineProperty(exports,"RealTimeEventType",{enumerable:!0,get:function get(){return _eventSource.RealTimeEventType}}),Object.defineProperty(exports,"Result",{enumerable:!0,get:function get(){return _tsRes.Result}}),Object.defineProperty(exports,"SDKConfigurationType",{enumerable:!0,get:function get(){return _types.SDKConfigurationType}}),Object.defineProperty(exports,"SDKCoreParameters",{enumerable:!0,get:function get(){return _types.SDKCoreParameters}}),Object.defineProperty(exports,"SdkLanguageType",{enumerable:!0,get:function get(){return _constants.SdkLanguageType}}),Object.defineProperty(exports,"ServerGetVisitorCodeParametersType",{enumerable:!0,get:function get(){return _types.ServerGetVisitorCodeParametersType}}),Object.defineProperty(exports,"TrackConversionParamsType",{enumerable:!0,get:function get(){return _types.TrackConversionParamsType}}),Object.defineProperty(exports,"TrackParametersType",{enumerable:!0,get:function get(){return _requester.TrackParametersType}}),Object.defineProperty(exports,"UserAgent",{enumerable:!0,get:function get(){return _kameleoonData.UserAgent}}),Object.defineProperty(exports,"VISITOR_CODE_LENGTH",{enumerable:!0,get:function get(){return _constants.VISITOR_CODE_LENGTH}}),Object.defineProperty(exports,"VariableType",{enumerable:!0,get:function get(){return _types.VariableType}});var _tsRes=require("ts-res"),_kameleoonClient=require("./kameleoonClient"),_kameleoonUtils=require("./kameleoonUtils"),_kameleoonError=require("./kameleoonError"),_storage=require("./storage"),_constants=require("./constants"),_campaignConfiguration=require("./campaignConfiguration"),_types=require("./types"),_kameleoonData=require("./kameleoonData"),_eventSource=require("./eventSource"),_requester=require("./requester");
2
- //# sourceMappingURL=index.js.map
package/dist/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["export { Ok, Result, Err } from 'ts-res';\nexport {\n KameleoonClient as KameleoonCore,\n IKameleoonClient as IKameleoonCore,\n} from './kameleoonClient';\nexport { KameleoonUtils as KameleoonCoreUtils } from './kameleoonUtils';\nexport { KameleoonException, KameleoonError } from './kameleoonError';\nexport {\n KameleoonStorageKey,\n IExternalStorage,\n IExternalStorageConstructor,\n} from './storage';\nexport { Cookie, VISITOR_CODE_LENGTH, SdkLanguageType } from './constants';\nexport { CLEANUP_TARGETING_DATA_INTERVAL } from './campaignConfiguration';\nexport { JSONType } from './campaignConfiguration';\nexport {\n Environment,\n VariableType,\n ExperimentType,\n FeatureFlagType,\n SDKCoreParameters,\n SDKConfigurationType,\n ExternalPackageInfoType,\n TrackConversionParamsType,\n FeatureVariableResultType,\n InternalSDKConfigurationType,\n GetFeatureFlagVariableParamsType,\n ServerGetVisitorCodeParametersType,\n ClientGetVisitorCodeParametersType,\n MobileGetVisitorCodeParametersType,\n Milliseconds,\n} from './types';\nexport {\n CustomData,\n Conversion,\n Device,\n Browser,\n UserAgent,\n DeviceType,\n BrowserType,\n PageView,\n KameleoonData,\n KameleoonDataType,\n PageViewParametersType,\n ConversionParametersType,\n} from './kameleoonData';\nexport {\n RealTimeEventType,\n IExternalEventSource,\n EventSourceOpenParametersType,\n IExternalEventSourceConstructor,\n} from './eventSource';\nexport {\n Header,\n HttpMethod,\n TrackParametersType,\n IExternalRequestDispatcher,\n GetClientConfigurationResultType,\n} from './requester';\n"],"mappings":""}