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

@ezmodo/flags-sdk

v0.1.0

Published

Isomorphic client SDK for evaluating ezmodo feature flags with a publishable client key

Readme

@ezmodo/flags-sdk

Isomorphic JS/TS client for evaluating ezmodo feature flags from untrusted code (browser, mobile, Node 18+) using a publishable client key (ezm_ck_…, scope client:eval).

Evaluation is server-side: the SDK ships inputs to the public endpoint and returns the server's result. It never re-implements evaluation — targeting rules, rollout buckets, and other-environment config stay on the server, so it is safe to ship the key in a client.

Full guide: vanilla JS / React-Next / Node quickstart + complete API reference is at docs/public/help/flags-sdk.md. A runnable React example is in examples/react.

Install

npm install @ezmodo/flags-sdk

Get a publishable key in ezmodo: Settings → API keys → Create → "Client key (publishable)". It starts with ezm_ck_ and is safe to embed in client code (it can only evaluate flags for the workspaces you select).

Usage

import { createClient } from '@ezmodo/flags-sdk'

const flags = createClient({
  publishableKey: 'ezm_ck_…',
  organizationId: 'org_123',
  environment: 'production', // optional; omitted → the flag's scope default
})

// Boolean flag with a safe default (never throws)
if (await flags.boolVariation('new-checkout', false)) {
  // …
}

// Multivariate / config value with a safe default (never throws)
const color = await flags.variation('theme-color', '#000000', {
  subjectId: 'user-1',
  attributes: { plan: 'pro' },
})

// Raw result (throws FlagsClientError on request failure)
const result = await flags.evaluate('new-checkout', { subjectId: 'user-1' })
// → { on, variantKey?, value?, reason }

// Batch — one round trip for the same subject
const results = await flags.evaluateAll(['a', 'b'], { subjectId: 'user-1' })

evaluateAll, variation, and boolVariation never throw — failed reads fall back to the last-known-good cached value or your default. evaluate returns a cached fallback when available, otherwise throws FlagsClientError.

Caching, batching & resilience

The client is efficient and flaky-network safe by default:

  • Caching — results are cached by (flagKey, subjectId, environment) for a TTL window (default 30s, aligned to the server flag-cache). Disable with cache: false or tune with cache: { ttlMs }.
  • Batching — concurrent evaluate calls made in the same tick are coalesced into a single /evaluate/batch request, and identical in-flight requests are deduped. Disable with batch: false.
  • Last-known-good — when a refresh fails, a cached value (even expired) is returned before falling back to a caller default. Observe failures via onError.
  • Prefetch — await flags.prefetch(['a', 'b']) warms the cache on init.
const flags = createClient({
  publishableKey: 'ezm_ck_…',
  organizationId: 'org_123',
  cache: { ttlMs: 60_000 },
  onError: (err, { flagKeys }) => console.warn('flag eval failed', flagKeys, err),
})
await flags.prefetch(['new-checkout', 'theme-color'])

Build & test

npm run build       # dual-format ESM + CJS into dist/
npm run type-check
npm test