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

@extn/segi-js

v0.2.11

Published

Browser JavaScript SDK for the segi error monitoring service

Downloads

164

Readme

@extn/segi-js

Browser JavaScript SDK for segi — error monitoring for teams that ship.

Install

pnpm add @extn/segi-js
# or: npm install @extn/segi-js
# or: yarn add @extn/segi-js

Use

import Segi from "@extn/segi-js";

Segi.init({
  publicKey: "segi_pk_live_...",
  // optional
  environment: "production",
  release: "1.4.2",
});

// anywhere
Segi.captureException(new Error("boom"));
Segi.captureMessage("checkout finished", { level: "info" });
Segi.setUser({ id: "user_123", email: "[email protected]" });
Segi.addBreadcrumb({ type: "click", message: "checkout button", timestamp: new Date().toISOString() });

Segi.init() is idempotent — calling it twice on the same bundle is a no-op. Pass { force: true } to replace the running config.

Session recording (planned)

A separate, tree-shakeable replay module ships alongside the error SDK — importing only Segi won't pull rrweb. Opt in per app, gated by your plan's recording quota (Free 10 / Team 30 / Enterprise ∞ per project per month).

import Segi from "@extn/segi-js";
import { withReplay } from "@extn/segi-js/replay";

Segi.init({
  publicKey: "segi_pk_live_...",
  replay: withReplay({
    enabled: true,
    sample: 100,                      // 0–100 probabilistic gate
    blockRoutes: ["/checkout", "/auth"],
    mask: { inputs: "all", class: "segi-mask" },
  }),
});

Segi.replay.pause();   // e.g. during a sensitive flow
Segi.replay.resume();

Default protections (cannot be turned off from the SDK): rrweb input masking for password/email/tel/number/text inputs, 3-minute idle pause, project-level deny-list editable from the segi dashboard. Full design: docs/12-session-recording.md.

CDN

Drop a <script> tag and skip the bundler:

<script src="https://cdn.extn.ai/segi/segi.min.js"></script>
<script>
  Segi.init({ publicKey: "segi_pk_live_..." });
</script>

Docs

Full integration guide: https://segi.extn.ai/docs

Licence

Copyright (c) 2026 Extension Co., Ltd. All rights reserved. Use of this package is governed by the LICENSE file in this package and the segi service Terms of Service at https://segi.extn.ai/tnc — it is not open source.