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

twd-runner

v0.1.1

Published

Cross-browser test runner for TWD tests using Playwright

Downloads

220

Readme

twd-runner

E2E Cross-Browser

Cross-browser headless test runner for TWD tests, built on Playwright. Runs your in-browser TWD tests across Chromium, Firefox, and WebKit in parallel and reports per-browser and aggregate results.

It is the cross-browser sibling of twd-cli. Unlike twd-cli, it does not collect code coverage or run API contract testing — it focuses purely on executing tests in every major browser engine.

Install

npm install -D twd-runner
npx playwright install

Usage

Start your dev server (with the TWD sidebar mounted), then:

npx twd-runner run

Exit code is 0 when every browser passes, 1 if any browser has a failing test or fails to launch.

Configuration

Reads the same twd.config.json as twd-cli (coverage/contract keys are ignored). Supported keys:

| Key | Default | Description | |---|---|---| | url | http://localhost:5173 | Dev server URL to test against | | timeout | 10000 | ms to wait for #twd-sidebar-root | | headless | true | Run browsers headless | | browsers | ["chromium","firefox","webkit"] | Which engines to run, in parallel | | launchArgs | [] | Extra args passed to every browser launch | | concurrency | 0 | Max browsers running at once. 0 means all in parallel. Set 1 (sequential) on constrained CI runners, where parallel engines contend for CPU and slow each other down. | | waitForServiceWorker | false | Wait for a service worker to control the page before running tests. Enable this for apps that mock requests via a service worker (e.g. MSW): Firefox/WebKit can be slow to take control, and mocks registered before then are silently lost. Leave false for apps with no service worker. |

If a configured browser isn't installed, the run prints npx playwright install <browser> and exits non-zero.

GitHub Action

This repo ships a reusable composite action that caches the Playwright browsers, installs them, and runs twd-runner across the configured engines. Add twd-runner to your project's devDependencies, start your dev server, then call the action:

name: Cross-browser

on:
  push:
    branches: [main]
  pull_request:
    branches: [main]

jobs:
  cross-browser:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v5
      - uses: actions/setup-node@v5
        with:
          node-version: 24
          cache: npm
      - run: npm ci

      - name: Start dev server
        run: |
          nohup npm run dev > dev.log 2>&1 &
          npx wait-on http://localhost:5173

      - name: Run TWD tests across browsers
        uses: BRIKEV/twd-runner/.github/actions/run@main
        with:
          working-directory: .   # directory containing twd.config.json (default ".")

The action reads twd.config.json and runs every engine listed in browsers (default: chromium, firefox, webkit), exiting non-zero if any browser has a failing test.