npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@configdirector/nextjs-sdk

v1.13.1

Published

Next.js SDK for ConfigDirector. ConfigDirector is a remote configuration and feature flag service.

Readme

ConfigDirector Next.js SDK

npm

Next.js SDK for ConfigDirector, remote config and feature flags with typed values, JSON Schema validation, and safe renames of live flags. Start free, no card required.

Install

npm install --save @configdirector/nextjs-sdk

Retrieve a value

// instrumentation.ts
export async function register() {
  const { register } = await import("@configdirector/nextjs-sdk/server");
  await register({ serverSdkKey: process.env["CONFIGDIRECTOR_SERVER_SDK_KEY"] });
}
// Any client component, inside the ConfigDirectorProvider from the root layout
"use client";
import { useConfigValue } from "@configdirector/nextjs-sdk/client";

const { value: darkMode } = useConfigValue("dark-mode", false);

Full details are in the official documentation.

Test your code

The /client/testing and /server/testing entry points create real clients connected to an in-memory server that your test controls, so components and server code run against the production SDK without opening a network connection or sending telemetry.

// Client Components: render the production provider with its client prop, or install the test client
import { act, render, screen } from "@testing-library/react";
import { ConfigDirectorProvider } from "@configdirector/nextjs-sdk/client";
import { createTestClient, installTestClient } from "@configdirector/nextjs-sdk/client/testing";

const testClient = createTestClient({ values: { "dark-mode": true } });
render(
  <ConfigDirectorProvider client={testClient.client}>
    <Page />
  </ConfigDirectorProvider>,
);
act(() => testClient.setValue("dark-mode", false));

const uninstall = installTestClient(testClient);
render(<AppWithItsOwnProvider />);
uninstall();
// Server code: install a server test client where register() would have put the singleton
import { createTestClient, installServerTestClient } from "@configdirector/nextjs-sdk/server/testing";
import { getConfigClient } from "@configdirector/nextjs-sdk/server";

const serverTestClient = createTestClient({ values: { "dark-mode": true } });
const uninstall = installServerTestClient(serverTestClient);
await serverTestClient.client.initialize();
getConfigClient().getValue("dark-mode", false, { id: "user-1" }); // true
uninstall();

A provider given a client reports it on the first render, never disposes it, removes its handlers when it unmounts, and does not initialize a client that is ready or initializing. installServerTestClient does not initialize the client; the test calls initialize, as register() would.

Documentation

Refer to the official documentation for the Next.js SDK.

There is also a quickstart guide for ConfigDirector and any of our SDKs.

Getting Help