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

@wristfit/react

v0.1.1

Published

React component for Wristfit's watch try-on: the shopper's own wrist, the watch on it at its true size

Readme

@wristfit/react

Wristfit's watch try-on as a React component: the shopper sets their wrist size, a 3D arm is built to it, and the watch goes on it at its true size, with how it fits ("good fit", "bold", …).

The try-on itself is served by Wristfit, so fixes and new features reach your site without a package update. This package loads its script and gives it a typed React API.

npm install @wristfit/react
import { WristfitTryOn } from "@wristfit/react";

<WristfitTryOn
  watch={{
    image: "/images/watch-front.jpg", // an <img>, a canvas, a Blob or an address on your own site
    diameterMm: 40,
    lugToLugMm: 47,                   // where you know them; measured or estimated otherwise
    thicknessMm: 11.2,
    dialMm: 33,                       // a round dial's opening, inside the bezel
    strap: "metal",
    clasp: { kind: "folding" },
  }}
  onFit={fit => console.log(fit.verdict, fit.lugToLugMm)}
/>

The picture is the watch front-on on a plain background, crown at 3 o'clock, as shops photograph them. It is read on your page's side (Wristfit's frame can't read another site's pictures) and sent to the try-on as image data; nothing is stored. Pass a new watch object to show another watch (memoise it so a re-render doesn't resend it), and wristMm when your page knows the shopper's wrist.

Without React, load the script and mount it:

<script src="https://wristfit-app.vercel.app/widget.js"></script>
<div id="try-on"></div>
<script>
  Wristfit.mount("#try-on", { watch: { image: document.querySelector("#product-photo"), diameterMm: 40 } });
</script>

or in one line, after the product photo:

<script src="https://wristfit-app.vercel.app/widget.js" data-image="#product-photo" data-diameter="40" data-strap="metal" async></script>

(data-lug-to-lug, data-thickness, data-lug-width and data-dial take the other sizes in mm.)

Events: ready, fit and error, as callbacks and as bubbling DOM events (wristfit:fit, …) on the element it is mounted in.