New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@statsig/js-client

Package Overview
Dependencies
Maintainers
5
Versions
105
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@statsig/js-client

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

  • 3.3.0-beta.1
  • npm
  • Socket score

Version published
Maintainers
5
Created

What is @statsig/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.

What are @statsig/js-client's main functionalities?

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);

Other packages similar to @statsig/js-client

FAQs

Package last updated on 21 Oct 2024

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc