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

react-native-cf-speedtest

v0.1.3

Published

Unofficial React Native network quality measurement library (Cloudflare speedtest methodology). Not affiliated with Cloudflare.

Readme

react-native-cf-speedtest

Measure internet connection quality (download/upload bandwidth, latency, jitter, AIM scores) in React Native apps against Cloudflare's edge network — a methodology-compatible port of @cloudflare/speedtest.

⚠️ Unofficial — not affiliated with or endorsed by Cloudflare. This is an independent, community-built library. It reuses the measurement methodology of the MIT-licensed @cloudflare/speedtest package (which powers speed.cloudflare.com), but Cloudflare, Inc. does not sponsor, support, or endorse this project. "Cloudflare" is a trademark of Cloudflare, Inc. See docs/adr/0006-naming-and-trademark.md.

Demo


Install

yarn add react-native-cf-speedtest
# or: npm install react-native-cf-speedtest

Requires React Native ≥ 0.76 (New Architecture / TurboModule). See Requirements.

npm: react-native-cf-speedtest · repo: Ky0-Nguyen/react-native-cf-speedtest

Run the demo (React Native CLI)

yarn
yarn example pod-install   # iOS — first time / after native changes
yarn example start         # Metro
# other terminal:
yarn example ios           # or: yarn example android

Details: example/README.md.

Why

@cloudflare/speedtest is browser-only. Pure-JS timing in React Native is inaccurate above roughly 200–300 Mbps (JS-thread jitter, GC, no PerformanceResourceTiming).

The fix: TypeScript orchestration (upstream methodology) + a thin native TurboModule for each timed transfer (URLSession / OkHttp). See docs/ARCHITECTURE.md.

Features

  • Download / upload bandwidth (ramp-up, p90), unloaded + loaded latency, jitter
  • AIM getScores() — streaming / gaming / video chatting (Bad → Great); packet loss optional (0 AIM points when not measured)
  • SpeedTest API + useSpeedTest() hook, progress stream, maxTotalBytes, metered-connection guard
  • Swift + Kotlin native transport (New Architecture)

UDP packet loss via TURN remains Phase 2.

Architecture overview

Business logic stays in TypeScript; native code only runs one timed transfer/probe and reports timing points.

Quick start

import { SpeedTest } from 'react-native-cf-speedtest';

const test = new SpeedTest({
  autoStart: true,
  maxTotalBytes: 50_000_000,
});

test.onResultsChange = () => {
  console.log(test.results.getSummary());
};

test.onFinish = (results) => {
  console.log(results.getSummary());
  console.log(results.getScores());
};

Media assets

Files under media/ used in this README (also shipped in the npm package):

| File | Type | Purpose | |------|------|---------| | media/demo-speedtest.mp4 | Video (MP4) | Example-app demo video | | media/demo-speedtest.gif | Animated GIF | Same demo for inline README preview | | media/demo-poster.png | Image (PNG) | Poster / thumbnail for the demo video | | media/architecture-overview.png | Image (PNG) | Exported architecture diagram | | media/paypal-donate.jpg | Image (JPEG) | PayPal donate QR |

Documentation

Full docs (PRD, API, native, epics, ADRs): docs/README.md

Requirements

| Requirement | Value | |---|---| | React Native | >= 0.76 (New Architecture; TurboModule-only — ADR-0004) | | iOS | 15.1+ | | Android | minSdk 24 | | Expo Go | Not supported (native module) |

A full uncapped run can transfer hundreds of MB — use maxTotalBytes and the metered-connection warning on mobile.

Roadmap

| Phase | Goal | |---|---| | Phase 1 | Core library + example + AIM scoring + npm (shipped) | | Phase 2 | Packet loss (TURN), Expo config plugin, CI polish |

Details: docs/ROADMAP.md.

Contributing

See CONTRIBUTING.md.

Donate

If this library helps your project, support development via PayPal:

After install, run npm fund react-native-cf-speedtest to open the same link.

License

MIT © 2026 Tuan Nguyen.

Methodology ported from @cloudflare/speedtest (MIT). Unofficial — not affiliated with Cloudflare, Inc.