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

@crxpay/react-paywall

v0.1.0

Published

Drop-in React paywall components for crxpay — themeable pricing tables, modals, entitlement gates.

Readme

@crxpay/react-paywall

Drop-in React paywall components for crxpay. Themeable pricing tables, paywall modals, and entitlement gates that hook directly into the @crxpay/sdk state machine.

If you ship a Chrome extension with React in the popup, options page, or new-tab override, this is the fastest path to a working paywall: drop <Paywall /> next to your free-tier UI and it will render, call checkout, and gate features when the subscription flips to active.

Install

npm install @crxpay/react-paywall @crxpay/sdk framer-motion
# or
pnpm add @crxpay/react-paywall @crxpay/sdk framer-motion

Peer dependencies: react >= 18, react-dom >= 18, framer-motion >= 11.

Don't forget to import the styles once (typically in your popup entry point):

import '@crxpay/react-paywall/styles.css';

Quick start

import { CrxPayProvider, Paywall, useEntitlement } from '@crxpay/react-paywall';
import '@crxpay/react-paywall/styles.css';

function App() {
  return (
    <CrxPayProvider apiKey="crxpay_pub_…">
      <Editor />
    </CrxPayProvider>
  );
}

function Editor() {
  const pro = useEntitlement('pro');

  if (!pro.isActive) {
    return <Paywall offeringId="default" onPurchased={() => pro.refresh()} />;
  }

  return <RealEditor />;
}

What's in the box

| Component | What it does | | ------------------------ | ---------------------------------------------------------------------------- | | <CrxPayProvider> | React context wrapper — feeds the SDK to all hooks/components below it. | | <Paywall> | The full paywall screen — pulls the offering from your dashboard, renders it. | | <PricingTable> | Just the plan cards, headless — useful if you're embedding in a custom UI. | | <EntitlementGate> | Wraps children; renders fallback if the entitlement isn't active. | | useEntitlement(key) | React hook — { isActive, isLoading, refresh }. | | useSubscription() | React hook — full subscription object + the live state machine. | | useOffering(offeringId)| React hook — fetches an offering's packages from the dashboard. |

Theming

Override the CSS variables in :root (or any wrapping element) to match your extension's brand:

:root {
  --crxpay-color-primary: #5E54F5;
  --crxpay-color-bg: #ffffff;
  --crxpay-color-text: #1F1F47;
  --crxpay-radius: 12px;
}

For full visual control, use the headless <PricingTable> and useEntitlement/useSubscription directly.

Templates

Eight paywall templates ship in dashboard.crxpay.io and are renderable by this component without any code change — the dashboard's visual editor outputs the same JSON the components consume here. Build once in the dashboard, ship to every user the next time the SDK polls (no Chrome Web Store re-review needed).

Links

License

MIT — see LICENSE.