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

@buildkitgg/shadcn-alerts-manager

v0.1.1

Published

Persistent inline alerts with shared behavior and interchangeable UI adapters.

Readme

@buildkitgg/shadcn-alerts-manager

Persistent inline alerts with external commands and shared lifecycle behavior.

Usage

import { createAlertManager, AlertRegion } from "@buildkitgg/shadcn-alerts-manager"

export const alerts = createAlertManager()
<AlertRegion manager={alerts} />

alerts.warning({ id: "billing", title: "Update your payment method" })

Behavior

  • add / info / success / warning / error: return a region-bound handle.
  • handle.update / handle.dismiss / handle.isActive: control that exact alert instance.
  • getSnapshot / subscribe: stable snapshots and region-scoped notifications.
  • dismissAll(region): remove alerts and invoke callbacks; flush(): clear all regions silently.
  • dispose(): clear silently, notify subscribers, and reject future additions.

Alerts are persistent. Use the native toast manager for timed feedback. Reusing an ID replaces in place without invoking dismissal; old handles become inactive. Mount once per region. Import styles.css once for the default kit. For registry components, pass adapter: alertComponents({ Alert, AlertTitle, AlertDescription, AlertAction, Button }); no Base UI/Radix switch is needed. Without AlertAction, the dismiss control sits beside the alert's action.

IDs are scoped to a region (default: default). All alerts are rendered; there is no hidden backlog or automatic timeout. dismissible: false hides the dismiss control but does not prevent programmatic dismissal. Actions do not automatically dismiss an alert. onDismiss runs once after removal, including dismissAll; it does not run for replacement, flush, or dispose. Callback errors are collected and re-thrown as an AggregateError after all notifications and dismissal callbacks have run.

Snapshots and entry containers are frozen. Generic payloads and React elements are not deep-frozen. Updates produce new entries, preserving previous snapshots. Treat payloads as immutable. Server snapshots are empty to avoid leaking request data; create stores per request, not as server singletons.

Import @buildkitgg/shadcn-alerts-manager/styles.css once, or use the kit stylesheet already loaded by the app. Custom registry components use their application CSS.

See alert architecture and native toast guidance.

Component style

Install @buildkitgg/shadcn-baseui-kit or alias a generated style under that name. The manager uses the app's peer implementation and stylesheet. Style selection needs no renderer adapter.

Localization and Tailwind

Default labels follow the selected kit’s ShadcnLocalizationProvider; explicit labels take precedence. See localization. For apps using the kit’s tailwind.css source entry, omit this manager’s stylesheet because it imports compiled kit utilities. The manager uses the component styles generated by your app.