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

errsight-rn

v0.1.0

Published

React Native client for ErrSight error tracking. Captures errors and log events from apps and ships them to the ErrSight API in batches.

Readme

errsight-rn

React Native client for ErrSight error tracking. Captures errors and log events from your app and ships them to the ErrSight API in batches.

Features

  • Automatic crash capture via React Native's ErrorUtils
  • Unhandled promise rejection tracking
  • React ErrorBoundary component
  • Batched event delivery with configurable flush interval
  • Automatic flush on app background/inactive
  • Log levels: debug, info, warning, error, fatal
  • User context (id, email) attached to every event
  • Device context (platform, OS, OS version) included automatically

Installation

npm install errsight-rn
# or
yarn add errsight-rn

Quick Start

Initialise the client once at app startup (e.g. in App.tsx):

import { init } from 'errsight-rn';

init({
  apiKey: 'elp_your_api_key_here',
  environment: 'production',
  minLevel: 'error',
});

That's it — unhandled errors and promise rejections are now captured automatically.

Configuration

| Option | Type | Default | Description | |--------|------|---------|-------------| | apiKey | string | required | Your project API key (elp_...) | | host | string | https://errsight.com | ErrSight API host | | environment | string | production | Environment name | | minLevel | string | error | Minimum level to capture (debug, info, warning, error, fatal) | | batchSize | number | 10 | Events per HTTP request | | flushInterval | number | 2000 | Background flush interval in ms | | captureGlobalErrors | boolean | true | Auto-capture crashes and unhandled rejections |

Manual Logging

import { getClient } from 'errsight-rn';

const client = getClient();

client?.debug('Cache miss', { metadata: { key: 'user:42' } });
client?.info('User signed in');
client?.warn('Deprecated API called');
client?.error('Payment failed', { metadata: { orderId: '123' } });
client?.fatal('Database unreachable');

Capturing Errors

try {
  await riskyOperation();
} catch (err) {
  client?.captureError(err, {
    metadata: { operation: 'riskyOperation' },
  });
}

User Context

Attach user info so errors are linked to the affected user:

// After sign-in
client?.setUser({ id: 42, email: '[email protected]' });

// After sign-out
client?.clearUser();

React Integration

ErrorBoundary

Wrap your component tree to catch render errors:

import { ErrorBoundary } from 'errsight-rn/react';

function App() {
  return (
    <ErrorBoundary fallback={<Text>Something went wrong.</Text>}>
      <MainScreen />
    </ErrorBoundary>
  );
}

With a render-prop fallback for reset:

<ErrorBoundary
  fallback={({ error, reset }) => (
    <View>
      <Text>{error.message}</Text>
      <Button title="Try again" onPress={reset} />
    </View>
  )}
>
  <Dashboard />
</ErrorBoundary>

ErrsightProvider & useErrsight

Access the client from any component via context:

import { ErrsightProvider, useErrsight } from 'errsight-rn/react';

function App() {
  return (
    <ErrsightProvider>
      <MainScreen />
    </ErrsightProvider>
  );
}

function MainScreen() {
  const logger = useErrsight();

  return (
    <Button
      title="Log event"
      onPress={() => logger?.info('Button pressed')}
    />
  );
}

Flushing & Shutdown

Events are flushed automatically every flushInterval ms and when the app moves to background. You can also flush manually:

// Flush immediately (e.g. before navigation)
client?.flush();

// Clean shutdown (flushes remaining events, removes listeners)
client?.shutdown();

License

MIT