Skip to content

Latest commit

 

History

History
73 lines (58 loc) · 4.12 KB

File metadata and controls

73 lines (58 loc) · 4.12 KB

LaunchDarkly JavaScript Observability SDK for Browsers

NPM Actions Status NPM NPM

NB: APIs are subject to change until a 1.x version is released.

Install

Install the package

# npm
npm i @launchdarkly/observability

# yarn
yarn add @launchdarkly/observability

Update your web app entrypoint.

import { initialize } from 'launchdarkly-js-client-sdk'
import Observability, { LDObserve } from '@launchdarkly/observability'

const client = init3(
        '<CLIENT_SIDE_ID>',
        { key: 'authenticated-user@example.com' },
        {
          // Not including plugins at all would be equivalent to the current LaunchDarkly SDK.
          plugins: [
            new Observability({
              networkRecording: {
                enabled: true,
                recordHeadersAndBody: true,
              },
            }),
          ],
        },
)

Getting started

Refer to the SDK documentation for instructions on getting started with using the SDK.

Verifying SDK build provenance with the SLSA framework

LaunchDarkly uses the SLSA framework (Supply-chain Levels for Software Artifacts) to help developers make their supply chain more secure by ensuring the authenticity and build integrity of our published SDK packages. To learn more, see the provenance guide.

About LaunchDarkly

  • LaunchDarkly Observability provies a way to collect and send errors, logs, traces to LaunchDarkly. Correlate latency or exceptions with your releases to safely ship code.
  • LaunchDarkly is a continuous delivery platform that provides feature flags as a service and allows developers to iterate quickly and safely. We allow you to easily flag your features and manage them from the LaunchDarkly dashboard. With LaunchDarkly, you can:
    • Roll out a new feature to a subset of your users (like a group of users who opt-in to a beta tester group), gathering feedback and bug reports from real-world use cases.
    • Gradually roll out a feature to an increasing percentage of users, and track the effect that the feature has on key metrics (for instance, how likely is a user to complete a purchase if they have feature A versus feature B?).
    • Turn off a feature that you realize is causing performance problems in production, without needing to re-deploy, or even restart the application with a changed configuration file.
    • Grant access to certain features based on user attributes, like payment plan (eg: users on the ‘gold’ plan get access to more features than users in the ‘silver’ plan).
    • Disable parts of your application to facilitate maintenance, without taking everything offline.
  • LaunchDarkly provides feature flag SDKs for a wide variety of languages and technologies. Read our documentation for a complete list.
  • Explore LaunchDarkly