Releases: statsig-io/js-client
v4.5.2 - Add ability to ignore local overrides, and get/set stableID
You can now ignore local gate/config overrides via a parameter on the checkGate and getConfig apis:
checkGate(gateName: string, ignoreOverrides?: boolean): boolean;
getConfig(configName: string, ignoreOverrides?: boolean): DynamicConfig;
getExperiment(
experimentName: string,
keepDeviceValue?: boolean,
ignoreOverrides?: boolean,
): DynamicConfig;
You can also override the internal stableID for the statsig SDK via StatsigOptions
:
export type StatsigOptions = {
overrideStableID?: string;
// existing options
api?: string;
disableCurrentPageLogging?: boolean;
environment?: StatsigEnvironment;
loggingIntervalMillis?: number;
loggingBufferMaxSize?: number;
disableNetworkKeepalive?: boolean;
};
This release also contains internal updates for the react sdk v1.0.0
v4.4.0 - Add support for "sticky" experiments
Adds the option to specify an experiment to be "sticky", i.e. once a user is in an experiment, they won't leave the experiment and their group will stay the same on the device until the experiment is concluded. It can be enabled with the new optional keepDeviceValue
parameter:
const myExp = statsig.getExperiment('my_experiment', true); // 2nd param is the new param
Also patches an issue where cached flag/config values were not used because callers were forced to wait for initialize() to resolve before checking gates/configs/experiments
New beta release
This beta release adds the option to specify an experiment to be "sticky", i.e. once a user is in an experiment, they won't leave the experiment and their group will stay the same on the device until the experiment is concluded. It can be enabled with the new optional keepDeviceValue
parameter:
const myExp = statsig.getExperiment('my_experiment', true); // 2nd param is the new param
v4.3.1 - Patch logEvent typing for react SDK
Internal typing patch for the logEvent API in the react SDK
v4.3.0 - Adds dynamic config overrides
Adds support for getAllOverrides(), overrideConfig(), and removeConfigOverride() for locally overriding dynamic configs in local storage. Since DynamicConfigs also back experiments, this can be used to locally override experiment payloads as well.
Marked getOverrides() and removeOverride() as deprecated, as they only deal with gate overrides.
Also contains internal updates to allow us to update the react SDK
v4.2.0 - add disableNetworkKeepalive option
Ensures all network requests from the SDK do not pass the keepalive parameter
v4.1.0 - More browser support and configurations for logging
Introduces new statsig options:
- loggingIntervalMillis: how frequently to flush logs to statsig (milliseconds). Default 5000 (5s), min 1000, max 60000
- loggingBufferMaxSize: maximum number of events to buffer before flushing events to statsig. Default 10, min 2, max 500
Along with this change we have added fallback logging endpoints to hit for better support for browsers which do not support the keepalive parameter (like firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1342484)
v4.0.4 - Patch identifier regression introduced in v4.0.1
The async storage change in v4.0.1 introduced a regression where the stable identifier was not set for non async storage clients (browsers)
v4.0.3 - Fix an issue with network retries hitting the incorrect url
Fixes an issue where network retries were not hitting the same url on the retry
v4.0.2 - Clear out failed network requests after resending
Patches an issue that would continue to resend failed logs by clearing out the cache of pending logs after sending