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

@vybesec/sdk

v0.1.12

Published

VybeSec browser SDK for error and security monitoring.

Downloads

1,313

Readme

@vybesec/sdk

Browser SDK for sending VybeSec events to your ingest endpoint. This package is browser-only (not intended for Node.js or React Native yet).

Server SDK inventory

  • Node.js: @vybesec/node
  • Supabase Deno: @vybesec/deno
  • Cloudflare Workers: @vybesec/cloudflare
  • Python: vybesec (PyPI)
  • Go: github.com/vybesec/vybesec-go
  • Ruby: vybesec (RubyGems)
  • PHP: vybesec/sdk (Composer)
  • Rust: vybesec (crates.io)

Install (npm)

npm install @vybesec/sdk
import { init, captureError, captureEvent } from "@vybesec/sdk";

init({
  key: "pk_xxxxxxxxxxxxxxxx",
  environment: "production",
  platform: "other"
});

captureError(new Error("Something broke"));

captureEvent({
  type: "custom",
  message: "Checkout completed",
  timestamp: Date.now(),
  extra: { orderId: "order_123" }
});

CDN (script tag)

<script src="https://cdn.vybesec.com/v1/sdk.js?v=20260326"></script>
<script>
  VybeSec.init({
    key: "pk_xxxxxxxxxxxxxxxx",
    environment: "production"
  });

  VybeSec.captureError(new Error("Something broke"));
</script>

Dev test snippet

Paste this into a dev page to confirm events are flowing:

<button id="vs-test-success">Trigger test success</button>
<button id="vs-test-error">Trigger test error</button>
<script>
  const sdk = window.VybeSec?.vybesec ?? window.VybeSec;
  document.getElementById("vs-test-success")?.addEventListener("click", () => {
    sdk?.captureEvent?.({
      type: "info",
      message: "VybeSec test success",
      timestamp: Date.now()
    });
  });
  document.getElementById("vs-test-error")?.addEventListener("click", () => {
    sdk?.captureError?.(new Error("VybeSec test error"));
  });
</script>

Configuration

| Option | Type | Description | Default | | --- | --- | --- | --- | | key | string | Project public key (DSN key). | Required | | environment | "production" | "staging" | "development" | Environment tag. | "production" | | platform | Platform | Tool/framework tag (examples: lovable, cursor, nextjs, react, vue, svelte, react-native, expo, other). | "other" | | release | string | Release identifier. | "" | | userId | string | User identifier. | undefined | | sampleRate | number | 0–1 sampling. | 1 | | maxBuffer | number | Max buffered events. | 100 | | maxEventsPerMinute | number | Client-side rate limit. | 120 |

Full platform list is documented in the VybeSec docs and kept in sync with the dashboard.

Events

captureError(error, context?)

Sends a normalized error event. Automatically attaches URL, session, environment, and release tags.

captureEvent(event)

Send a custom event. The SDK normalizes and scrubs sensitive values.

Supported event shape:

type RawEvent = {
  type: "error" | "warning" | "info" | "performance" | "custom";
  message: string;
  stackTrace?: string;
  errorType?: string;
  url?: string;
  requestUrl?: string;
  requestMethod?: string;
  responseStatus?: number;
  sessionId?: string;
  userId?: string;
  timestamp: number;
  tags?: Record<string, string>;
  extra?: Record<string, unknown>;
};

Automatic instrumentation

The SDK captures:

  • window.error and unhandledrejection
  • Failed fetch and XHR responses
  • SPA navigation changes
  • Flushes queued events on tab close / hidden

Backward compatibility policy

We treat patch and minor releases as backward compatible for the public API:

  • init, captureError, captureEvent, and the global VybeSec object

Breaking changes will only ship with a major version bump and will be documented in the changelog.

Security & PII

The SDK scrubs obvious secrets (API keys, passwords, bearer tokens) before sending events. If you need deeper redaction, use a custom captureEvent wrapper to scrub payloads before calling the SDK.