
Security News
Vite+ Joins the Push to Consolidate JavaScript Tooling
Evan You announces Vite+, a commercial, Rust-powered toolchain built on the Vite ecosystem to unify JavaScript development and fund open source.
@launchdarkly/vercel-server-sdk
Advanced tools
This library supports using Vercel Edge Config to replace the default in-memory feature store of the LaunchDarkly Node.js SDK.
This SDK requires LaunchDarkly's Vercel integration to push feature flag data into a Vercel Edge Config. The Vercel integration is available to customers on an Enterprise plan. To learn more, read about our pricing. To upgrade your plan, contact Sales.
For more information, see the Vercel SDK reference.
npm i @launchdarkly/vercel-server-sdk
or yarn:
yarn add -D @launchdarkly/vercel-server-sdk
Initialize the ldClient with the Vercel Edge SDK and your LaunchDarkly client-side ID:
import { createClient } from '@vercel/edge-config';
import { init } from '@launchdarkly/vercel-server-sdk';
const edgeClient = createClient(process.env.EDGE_CONFIG);
const ldClient = init('YOUR CLIENT-SIDE ID', edgeClient);
await ldClient.waitForInitialization();
const ldContext = {
kind: 'org',
key: 'my-org-key',
someAttribute: 'my-attribute-value',
};
const flagValue = await ldClient.variation('my-flag', ldContext, true);
To learn more, see the examples in this repository or head straight to the complete reference guide for this SDK.
⚠️ experimental
This SDK has experimental support for sending analytic events to LaunchDarkly. It can be enabled by setting
sendEvents
totrue
in the SDK options.
const client = initLD(sdkKey, env.LD_KV, { sendEvents: true });
# at js-core repo root
yarn && yarn build && cd packages/sdk/vercel
# run tests
yarn test
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.
FAQs
LaunchDarkly Server-Side SDK for Vercel Edge
The npm package @launchdarkly/vercel-server-sdk receives a total of 8,810 weekly downloads. As such, @launchdarkly/vercel-server-sdk popularity was classified as popular.
We found that @launchdarkly/vercel-server-sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer 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
Evan You announces Vite+, a commercial, Rust-powered toolchain built on the Vite ecosystem to unify JavaScript development and fund open source.
Security News
Ruby Central’s incident report on the RubyGems.org access dispute sparks backlash from former maintainers and renewed debate over project governance.
Research
/Security News
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.