
Security News
vlt Launches "reproduce": A New Tool Challenging the Limits of Package Provenance
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
@statsig/js-client
Advanced tools
> [!IMPORTANT] > This version of the SDK is still in beta. The non-beta version can be found [here](https://github.com/statsig-io/js-client).
@statsig/js-client is a JavaScript client library for integrating with Statsig, a feature management and experimentation platform. It allows developers to manage feature flags, run A/B tests, and gather insights on user behavior to make data-driven decisions.
Initialize Statsig Client
This feature allows you to initialize the Statsig client with your client API key, which is necessary to start using the Statsig services in your application.
const statsig = require('@statsig/js-client');
statsig.initialize('client-api-key');
Check Feature Gate
This feature allows you to check if a particular feature gate is enabled for the current user. It helps in conditionally rendering features based on the gate status.
const isFeatureEnabled = statsig.checkGate('new_feature');
console.log(isFeatureEnabled);
Get Experiment Parameter
This feature allows you to retrieve a specific parameter from an experiment, enabling you to customize user experiences based on experiment configurations.
const parameter = statsig.getExperimentParameter('experiment_name', 'parameter_name');
console.log(parameter);
LaunchDarkly is a feature management platform that provides similar functionality to Statsig, such as feature flagging and experimentation. It offers a robust set of tools for managing feature releases and conducting A/B tests, with a focus on real-time updates and scalability.
Unleash is an open-source feature management solution that provides feature toggling capabilities. It is a lightweight alternative to Statsig, focusing on simplicity and ease of integration, especially for teams looking for an open-source option.
[!IMPORTANT] This version of the SDK is still in beta. The non-beta version can be found here.
The JavaScript SDK for single user client environments. If you need a SDK for another language or server environment, check out our other SDKs.
Statsig helps you move faster with feature gates (feature flags), and/or dynamic configs. It also allows you to run A/B/n tests to validate your new features and understand their impact on your KPIs. If you're new to Statsig, check out our product and create an account at statsig.com.
Check out our SDK docs to get started.
FAQs
Statsig helps you move faster with feature gates (feature flags), and/or dynamic configs. It also allows you to run A/B/n tests to validate your new features and understand their impact on your KPIs. If you're new to Statsig, check out our product and cre
The npm package @statsig/js-client receives a total of 110,975 weekly downloads. As such, @statsig/js-client popularity was classified as popular.
We found that @statsig/js-client demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
Research
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.