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

@seekite/react

v0.1.0-alpha.0

Published

Accessible React search components for Seekite

Readme

@seekite/react

Accessible, drop-in React search UI for Seekite. It pairs the headless state machine from @seekite/search-ui with an inline combobox, a portal dialog, and composable primitives. React and React DOM stay peer dependencies, and styling is a standalone zero-runtime CSS file.

Install

pnpm add @seekite/core @seekite/search-ui @seekite/react

Import the default theme once in your application:

import "@seekite/react/style.css"

Drop-in dialog

import { createSearch } from "@seekite/core"
import { SearchDialog, SeekiteProvider, useSeekite } from "@seekite/react"

const client = createSearch({ url: "/search" })

function OpenSearch() {
  const [, search] = useSeekite()
  return <button onClick={() => search.open()}>Search docs</button>
}

export function App() {
  return (
    <SeekiteProvider
      client={client}
      options={{ queryOptions: { corpora: ["docs"], facets: ["tags"] } }}
    >
      <OpenSearch />
      <SearchDialog
        label="Search documentation"
        onResultSelect={(result) => location.assign(result.url)}
      />
    </SeekiteProvider>
  )
}

SearchDialog portals into document.body only while the controller is open. It traps focus, locks body scrolling, restores the previously focused element, and closes when its backdrop is pressed. ⌘K (macOS) or Ctrl+K opens it by default; set keyboardShortcut={false} when the host application owns that binding. Pass portalContainer to target a different element. The closed server render does not read window or document.

For a header or sidebar, replace the trigger and dialog with:

<SearchBox
  placeholder="Search guides…"
  onResultSelect={(result) => navigate(result.url)}
/>

Compose your own UI

All prebuilt views are compositions of the same primitives:

import { Search } from "@seekite/react"

function CustomSearch() {
  return (
    <section>
      <Search.Input aria-label="Search API reference" />
      <Search.Facets fields={["version"]} />
      <Search.Empty>No matching API pages.</Search.Empty>
      <Search.Results />
      <Search.LoadMore />
    </section>
  )
}

Search.Results provides corpus groups and default result rows. Supply renderResult={(result, index) => <Search.Result result={result} index={index}>…</Search.Result>} for custom rows, or pass explicit Search.Result children. Search.Snippet renders core highlight ranges with semantic <mark> elements.

useSeekite() returns the immutable [state, controller] pair. This is also the escape hatch for opening and closing views, showing recents, or binding a product-specific keyboard shortcut.

Keyboard and accessibility contract

  • The input follows the WAI-ARIA combobox pattern and owns a grouped listbox.
  • Up/Down wraps through results; Enter resolves and persists the selected result. Escape clears a non-empty query first, then closes on the next press.
  • Result-count and loading changes are announced through a polite live region.
  • Facet chips are labelled toggle buttons, and all built-in controls expose visible focus indicators.

Theme

Override any --seekite-* variable, such as --seekite-accent, --seekite-radius, --seekite-font, --seekite-z-index, or --seekite-dialog-width. The stylesheet follows prefers-color-scheme and supports explicit data-theme="light" / data-theme="dark" overrides.