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

@ripplo/testing

v0.8.0

Published

Typed test DSL for Ripplo — declare entities and user flows, compile to a lockfile

Readme

@ripplo/testing

Typed test DSL for Ripplo. You declare your app's state model and user flows in TypeScript; Ripplo compiles them to a lockfile and executes them against your real app with real backend state.

This package is the authoring surface. Execution lives in the ripplo CLI.

Install

npx ripplo setup (guided, via the Claude Code plugin) or npx ripplo init (by hand) scaffolds .ripplo/, installs this package, and wires env vars.

The model

A project has four layers, all plain TypeScript under .ripplo/:

  • Entities — the state model. Each entity declares its fields as value-spaces (v.email(), v.number({ min, max }), ...) and gets a seed/read implementation in your app's engine.
  • Singletons — client/global state (e.g. localStorage flags).
  • Worlds — pure functions returning a record of entity handles: the starting state a test runs against.
  • Teststest("Intent", () => ({ given, steps })). given arranges; steps act and assert.
import { button, click, fill, goto, test, textbox, visible } from "@ripplo/testing";
import { Task } from "../entities/index.js";
import { ownedProject } from "../worlds/index.js";

export const createTask = test("Create a task", () => {
  const { me, project } = ownedProject();
  return {
    given: [me, project],
    steps: [
      goto`/projects/${project.id}/tasks`.expect(visible(button("New"))),
      click(button("New")).expect(visible(textbox("Title"))),
      fill(textbox("Title"), "Buy milk"),
      click(button("Create")).expect(Task.created({ title: "Buy milk", projectId: project.id })),
    ],
  };
});

arbitrary(Entity.field.x) draws a fresh value per run from the field's value-space, so tests exercise the space instead of one hardcoded value. Backend effects (created, updated, deleted) are checked by an oracle that compares model-before, predicted-after, and observed state.

The complete primitive catalog — every action, locator, predicate, field axis, and assertion — is in DSL.md, shipped with the package.

The engine adapter

Your app exposes a test engine: seed/read implementations for each declared entity, mounted behind a signed-webhook endpoint that runs only when explicitly enabled.

// src/test/engine.ts
import { createEngine } from "@ripplo/testing";
import ripplo from "../../.ripplo/index.js";
import { impls } from "./impls.js";

export const engine = createEngine(ripplo, { entities: impls, singletons: {} }, teardown);

Mount it on whatever server you run. Every adapter exposes the same three signed PUT routes — /setup, /state, /teardown — under the prefix you mount it at. Point RIPPLO_ENGINE_URL at that prefix.

// Express
import { createEngineHandler } from "@ripplo/testing/express";
app.use("/ripplo", createEngineHandler({ enabled, engine }));

// Fastify
import { registerFastifyHandler } from "@ripplo/testing/fastify";
app.register(registerFastifyHandler({ enabled, engine }), { prefix: "/ripplo" });

// Hono
import { createHonoHandler } from "@ripplo/testing/hono";
app.route("/ripplo", createHonoHandler({ enabled, engine }));

// Koa
import { createKoaHandler } from "@ripplo/testing/koa";
app.use(createKoaHandler({ enabled, engine }));

// Elysia
import { createElysiaHandler } from "@ripplo/testing/elysia";
app.use(createElysiaHandler({ enabled, engine }));

// Next.js — app/ripplo/[action]/route.ts
import { createNextHandler } from "@ripplo/testing/nextjs";
export const PUT = createNextHandler({ enabled, engine });

// NestJS — functional middleware
import { createNestHandler } from "@ripplo/testing/nestjs";
consumer.apply(createNestHandler({ enabled, engine })).forRoutes("ripplo");

enabled gates the adapter — leave it off in production. TypeScript enforces one implementation per declared entity; a missing or duplicate impl is a compile error.

Compile, commit, run

npx ripplo compile  # analyze + typecheck .ripplo/ → ripplo.lock
npx ripplo run      # execute against your local app via the daemon

Commit .ripplo/ripplo.lock alongside your test changes. The Ripplo server reads it verbatim on every push.

License

© Ripplo LLC. All rights reserved. Use is subject to Ripplo's Terms of Service.