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

@nks-hub/rybbit-ts

v0.1.0

Published

NKS Rybbit SDK - wrapper around Rybbit Analytics with event management, GTM bridge, and fallback loading

Downloads

13

Readme

@nks-hub/rybbit-ts

Build Status npm version License: MIT

Privacy-first analytics SDK for TypeScript - A modern wrapper for Rybbit Analytics with typed events, GTM integration, and zero-configuration setup.


Why Rybbit?

Privacy-first. Cookieless. No consent popups needed.

Rybbit Analytics provides GDPR-compliant, cookieless tracking without requiring user consent dialogs. This SDK makes integration effortless with:

  • Zero cookies - No consent banners required
  • TypeScript-first - Fully typed GA4-compatible events
  • GTM-ready - Seamless Google Tag Manager bridge
  • Queue management - Never lose events during initialization
  • Multiple loading strategies - Works with any setup

Quick Start

Installation

npm install @nks-hub/rybbit-ts

Usage

ES Module

import nksRybbit from '@nks-hub/rybbit-ts';

// Initialize SDK
await nksRybbit.boot({
  host: 'https://demo.rybbit.com',
  siteId: 'your-site-id'
});

// Track events
nksRybbit.event('click_cta', { button: 'hero' });

// E-commerce tracking
nksRybbit.trackPurchase({
  transactionId: 'TX-001',
  value: 1299,
  currency: 'CZK'
});

Script Tag (IIFE)

<script src="https://cdn.example.com/nks-rybbit.iife.min.js"></script>
<script>
  NksRybbit.default.boot({
    host: 'https://demo.rybbit.com',
    siteId: 'your-site-id'
  });

  NksRybbit.default.event('page_view');
</script>

Features

| Feature | Description | |---------|-------------| | 3 Loading Strategies | Script injection, @rybbit/js SDK integration, or auto-detect | | Event Queuing | Buffers events before SDK ready, replays on initialization | | Typed Events | Full TypeScript support for GA4-compatible events (purchase, add_to_cart, view_item, etc.) | | GTM Bridge | Auto-forward Google Tag Manager dataLayer events to Rybbit | | User Identification | Automatic user ID extraction from server-rendered DOM | | Dry-run Mode | Test integration by logging events without sending | | Session Replay | Programmatic control over session recording |


Documentation

Comprehensive guides to get you up and running:

| Guide | Description | |-------|-------------| | Getting Started | Installation, configuration, and loading strategies | | Events Reference | Complete catalog of typed events with examples | | GTM Bridge | Google Tag Manager integration guide | | API Reference | Full SDK API documentation | | Examples | Real-world integration examples |


Build Outputs

| File | Format | Size | Use Case | |------|--------|------|----------| | dist/index.esm.js | ESM | ~24 KB | Modern bundlers (Vite, webpack, Rollup) | | dist/index.js | CJS | ~25 KB | Node.js / require() imports | | dist/index.iife.js | IIFE | ~26 KB | Direct script tag (development) | | dist/index.iife.min.js | IIFE | ~13 KB | Direct script tag (production) | | dist/index.d.ts | Types | ~10 KB | TypeScript definitions |


Configuration Example

import nksRybbit from '@nks-hub/rybbit-ts';

await nksRybbit.boot({
  // Required
  host: 'https://demo.rybbit.com',
  siteId: 'your-site-id',

  // Optional
  loadStrategy: 'detect',             // 'detect' | 'script' | 'sdk'
  debug: false,                       // Console logging
  dryRun: false,                      // Test mode (log only)
  gtmBridge: true,                    // Forward GTM events
  gtmEvents: ['purchase'],            // Whitelist GTM events
  autoIdentify: true,                 // Auto-detect user from DOM
  globalProperties: { site: 'my-site' }
});

Development

# Install dependencies
npm install

# Build SDK
npm run build

# Type checking
npm run typecheck

# Run tests
npm test

# Watch mode
npm run dev

Requirements

  • Node.js: 16+ recommended
  • TypeScript: 5.0+ (for TypeScript projects)
  • Browsers: Modern browsers with ES6 support

License

MIT License - see LICENSE file for details.


Links


Made with privacy in mind - No cookies, no consent popups, no tracking bloat.