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

@manojskidos/skilink-web-sdk

v0.1.1

Published

Skilink Web SDK — track events, identify users, unify cross-device identity from browsers.

Readme

Skilink Web SDK

Tiny, dependency-free web SDK for sending events and identifying users to the Skilink customer engagement platform. Mirrors the iOS SDK identity model so users registering on iOS or web land in the same record.

  • ~5 KB minified + gzipped (single file, no deps).
  • 5-method public API: init, track, identify, setUser, reset.
  • Automatic anonymous-to-known identity merge on login (identify).
  • Optional auto-pageview tracking (SPA-aware via history.pushState patching).
  • Resilient: failed events queue in localStorage and retry on next page load.

Install

Script tag (zero-build pages)

<script src="https://cdn.your-host.com/skilink.min.js"></script>
<script>
  Skilink.init({ apiKey: 'YOUR_PUBLIC_API_KEY' });
</script>

npm

npm install @infyu/skilink-web-sdk
import Skilink from '@infyu/skilink-web-sdk';
Skilink.init({ apiKey: 'YOUR_PUBLIC_API_KEY' });

API

Skilink.init(options)

Call once on page load. Idempotent.

| Option | Type | Default | Notes | |------------------|-----------|------------------------------------|-------------------------------------------------| | apiKey | string | required | Your Skilink client key. | | apiHost | string | https://skilink-api.skidos.com | Override for staging. | | autoPageviews | boolean | true | Set false to track pageviews manually. |

On first visit, init POSTs /api/web-sdk/user-tracking/generate-luid and persists the returned anonymous luid in localStorage. Subsequent visits skip the call.

Skilink.track(eventName, attributes?)

Fire an event. Best-effort — never throws. If the network is down, the event is queued in localStorage and replayed on the next page load.

Skilink.track('signup_clicked', { plan: 'pro', referrer: 'homepage' });

Skilink.identify(cuid, traits?)

Link the current anonymous browser session to a known user. Triggers the backend's identity-merge flow: historical anonymous events get re-pointed to the known user's record (matches what the iOS SDK does on login).

// After your registration form succeeds:
await Skilink.identify(user.id, {
    email:     user.email,
    firstName: user.firstName,
    lastName:  user.lastName,
    timezone:  Intl.DateTimeFormat().resolvedOptions().timeZone
});

Calling identify with the same cuid is safe — the backend detects the existing match and updates traits without re-merging.

Skilink.setUser(traits)

Update profile fields without changing identity. Use this for incremental profile enrichment after registration.

Skilink.setUser({ company: 'Acme Inc.', plan: 'enterprise' });

Skilink.reset()

Call on logout. Clears the cuid binding so subsequent events go back to anonymous attribution. The luid persists, so the same browser is still recognized as the same anonymous visitor.

function onLogout() {
    Skilink.reset();
}

Recipe: registration funnel

// 1. Page load — anonymous tracking starts immediately.
Skilink.init({ apiKey: 'k_live_...' });

// 2. User enters the funnel.
Skilink.track('signup_started');

// 3. User submits the form. Identity is now known.
const user = await api.signup(formData);
await Skilink.identify(user.id, {
    email:     user.email,
    firstName: user.firstName,
    lastName:  user.lastName
});

// 4. Subsequent events are attributed to the known user.
Skilink.track('signup_completed', { plan: user.plan });

Recipe: cross-device identity (iOS + web)

If a user registers on iOS and later visits your web app while logged in:

// On a page where you know who the user is server-side, re-identify them.
// The backend uses the same identity flow whether the call comes from iOS
// or web, so the user's events stay unified across devices.
Skilink.init({ apiKey: 'k_live_...' });
Skilink.identify(SERVER_KNOWN_USER_ID, {
    email: SERVER_KNOWN_EMAIL
});

How identity works

| State | What's persisted | Sent on every event | |----------------------------------|---------------------------------|-------------------------------| | First visit | luid (issued by server) | userId = luid, luid | | After identify(cuid) | luid + cuid | userId = cuid, cuid, luid| | After reset() | luid only | userId = luid, luid |

The same payload shape is used by the iOS SDK, so a user's events from iOS and web flow through the same backend pipeline.

Privacy

  • Storage: only localStorage (no cookies, no third-party tracking).
  • No fingerprinting — language and timezone come from standard browser APIs the user already exposes to every site.
  • No precise location — never prompts for navigator.geolocation.
  • Network: only POSTs to your configured apiHost. No third-party calls.

Browser support

Modern evergreens (Chrome, Edge, Firefox, Safari). Built with target: es2018, so async/await + spread/rest work natively without polyfills.

Development

npm install
npm test         # run unit tests
npm run build    # produces dist/skilink.{min,esm,cjs}.js

License

UNLICENSED — internal Infyu / Skidos use.