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

@deksden-com/cpa-kit-react

v0.1.3

Published

Portable, host-authenticated CPA console. No login page, router, Next.js, Tailwind scanner or toast provider is required.

Readme

CPA Kit React

Portable, host-authenticated CPA console. No login page, router, Next.js, Tailwind scanner or toast provider is required.

Available on npm: pnpm add @deksden-com/cpa-kit-react @deksden-com/cpa-kit. No install token required.

import { useMemo } from 'react';
import { createCpaAdminClient } from '@deksden-com/cpa-kit/client';
import { CpaConsole } from '@deksden-com/cpa-kit-react';
import '@deksden-com/cpa-kit-react/styles.css';

export function Administration({ csrfToken }: { csrfToken: string }) {
  const client = useMemo(() => createCpaAdminClient({
    baseUrl: '/api/cpa', instanceId: 'primary',
    headers: () => ({ 'X-CSRF-Token': csrfToken }),
  }), [csrfToken]);
  return <CpaConsole client={client} instanceId="primary" locale="ru" theme="dark" />;
}

Documentation index: installation, host API and safe runtime updates. React and React DOM 19.2.x are required; use the matching core peer version.

Memoize the scoped client for the lifetime of the instance. initialPanel provides internal navigation; panel + onNavigate allows a host router to control navigation. initialOperationId resumes a durable job after reload; onOperationChange lets the host put its safe operation ID in the URL. The package never stores credentials, files or management/inference keys in browser storage. The host must authenticate and authorize every read/mutation, enforce same-origin/CSRF and execute the accepted operation in a durable worker.

initialCandidateId can reopen an owner-authorized import preview, including an alias resolved by the host API. Apply/cancel always use the canonical candidateId from the validated preview response, never the URL alias. Capability modes and overwrite govern the available import controls; absent policy fails closed. PG merge-only pools cannot select full replacement or overwrite existing identities.

Individual CpaOverviewPanel, CpaCredentialsPanel, CpaModelsPanel, CpaVersionsPanel, and CpaOperationsPanel use the same props; when controlled the host must handle onNavigate. locale supports Russian and English; labels overrides phrasing without a mandatory i18n dependency. probeProtocols and reasoningProfiles must match host-approved probe policies. A probe always requires explicit confirmation. Missing capabilities show disabled actions with reason codes; management unavailability does not imply inference failure.

Import is one ZIP/JSON control, with an optional native directory picker inside a disclosure. Unsupported directory pickers fall back to ZIP. Preview is explicit, and deletions must be confirmed. Polling is 1 second active/5 seconds hidden, transient backoff capped at 30 seconds, stopped at terminal or recovery state and aborted on unmount. The redacted operation outcome is displayed inline, not only as a transient toast.

All styles are scoped under .cpa-kit, with overridable --cpa-* CSS custom properties. No fonts or global reset are injected. Light/dark, reduced-motion-compatible static UI, 320px layout and keyboard focus are supported. Keys and upstream error bodies must not be passed as props.