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

create-playwright-ai

v1.0.0

Published

Scaffold a Playwright + AI reporting test project in seconds

Readme

create-playwright-ai

Scaffold a Playwright E2E test project with AI-powered reporting and a GitHub Actions CI pipeline — in seconds.

npm create playwright-ai@latest my-project

The CLI will ask for a project name and your preferred language (English or Spanish). The prompts/ directory will be generated in the chosen language, so Claude's AI reports will be written in that language too.


What you get

my-project/
├── .github/
│   └── workflows/
│       └── ai-triage.yml       # CI pipeline: static review + E2E + AI report
├── prompts/                    # in your chosen language (en / es)
│   ├── ai-corrections.txt      # prompt → suggested code fixes
│   ├── ai-group-failures.txt   # prompt → group failures by root cause
│   ├── ai-summary.txt          # prompt → business-friendly summary
│   └── ai-tickets.txt          # prompt → Jira-ready ticket drafts
├── scripts/
│   └── report-ai.mjs           # local AI report generator (uses Claude CLI)
├── src/
│   └── pages/
│       └── login.page.ts       # Page Object Model example
├── tests/
│   └── login.spec.ts           # login test suite (3 tests)
├── playwright.config.ts
├── tsconfig.json
└── .gitignore

Requirements

  • Node.js 18 or higher
  • Claude Code CLI installed and authenticated (for local AI reports)

Usage

# scaffold the project
npm create playwright-ai@latest my-project

# move into the folder
cd my-project

# install Playwright browsers
npx playwright install

# run the tests
npm run test

# run tests + generate AI report (requires Claude CLI)
npm run test:ai

Available scripts

| Script | Description | |--------|-------------| | npm run test | Run all tests (headless) | | npm run test:headed | Run tests with the browser visible | | npm run test:ui | Open the Playwright interactive UI | | npm run report:ai | Generate AI report from the last test run | | npm run test:ai | Run tests and immediately generate the AI report |

GitHub Actions CI pipeline

The included workflow (ai-triage.yml) runs automatically on every pull request and has three jobs:

  1. Static code review — Claude reads the PR diff and posts a Markdown comment with Playwright best-practice feedback.
  2. E2E tests — Runs the full Playwright test suite on ubuntu-latest.
  3. AI quality report — If any test fails, Claude groups the failures, writes a business summary, generates Jira-ready ticket drafts, and posts everything as a PR comment. It also applies a risk label (ai:critical-risk, ai:needs-review, or ai:low-risk) to the PR automatically.

Required secret

Add this secret to your GitHub repository (Settings → Secrets → Actions):

| Secret | Description | |--------|-------------| | CLAUDE_CODE_OAUTH_TOKEN | Your Claude Code OAuth token |

Local AI report

After running your tests, execute npm run report:ai to generate these files inside playwright-report/:

  • ai-summary.txt — plain-text executive summary (business-friendly, ready to email)
  • ai-corrections.md — suggested fixes per failure group
  • ai-tickets.json — Jira-compatible ticket drafts
  • ai-failures-grouped.json — failures grouped by root cause


create-playwright-ai (Español)

Genera un proyecto de tests E2E con Playwright, informes con IA y un pipeline de CI en GitHub Actions — en segundos.

npm create playwright-ai@latest mi-proyecto

La CLI te pedirá el nombre del proyecto y tu idioma preferido (English o Español). El directorio prompts/ se generará en el idioma elegido, y los informes que genere Claude también estarán en ese idioma.


Qué incluye el proyecto generado

mi-proyecto/
├── .github/
│   └── workflows/
│       └── ai-triage.yml       # pipeline CI: revisión estática + E2E + informe IA
├── prompts/                    # en el idioma elegido (en / es)
│   ├── ai-corrections.txt      # prompt → correcciones de código sugeridas
│   ├── ai-group-failures.txt   # prompt → agrupa fallos por causa raíz
│   ├── ai-summary.txt          # prompt → resumen ejecutivo para negocio
│   └── ai-tickets.txt          # prompt → borradores de tickets para Jira
├── scripts/
│   └── report-ai.mjs           # generador de informes IA en local (usa Claude CLI)
├── src/
│   └── pages/
│       └── login.page.ts       # ejemplo de Page Object Model
├── tests/
│   └── login.spec.ts           # suite de login (3 tests)
├── playwright.config.ts
├── tsconfig.json
└── .gitignore

Requisitos

  • Node.js 18 o superior
  • Claude Code CLI instalado y autenticado (para los informes IA en local)

Uso

# genera el proyecto
npm create playwright-ai@latest mi-proyecto

# entra en la carpeta
cd mi-proyecto

# instala los navegadores de Playwright
npx playwright install

# ejecuta los tests
npm run test

# ejecuta los tests y genera el informe IA (requiere Claude CLI)
npm run test:ai

Scripts disponibles

| Script | Descripción | |--------|-------------| | npm run test | Ejecuta todos los tests (sin navegador visible) | | npm run test:headed | Ejecuta los tests con el navegador visible | | npm run test:ui | Abre la interfaz interactiva de Playwright | | npm run report:ai | Genera el informe IA a partir del último resultado | | npm run test:ai | Ejecuta los tests y genera el informe IA inmediatamente |

Pipeline de GitHub Actions

El workflow incluido (ai-triage.yml) se ejecuta automáticamente en cada pull request y tiene tres jobs:

  1. Revisión estática del código — Claude lee el diff del PR y publica un comentario Markdown con feedback sobre buenas prácticas de Playwright.
  2. Tests E2E — Ejecuta la suite completa de Playwright en ubuntu-latest.
  3. Informe de calidad con IA — Si algún test falla, Claude agrupa los fallos, escribe un resumen de negocio, genera borradores de tickets para Jira y publica todo como comentario en la PR. Además aplica automáticamente una etiqueta de riesgo (ai:critical-risk, ai:needs-review o ai:low-risk).

Secret necesario

Añade este secret en tu repositorio de GitHub (Settings → Secrets → Actions):

| Secret | Descripción | |--------|-------------| | CLAUDE_CODE_OAUTH_TOKEN | Tu token OAuth de Claude Code |

Informe IA en local

Después de ejecutar tus tests, lanza npm run report:ai para generar estos archivos dentro de playwright-report/:

  • ai-summary.txt — resumen ejecutivo en texto plano (listo para enviar por email)
  • ai-corrections.md — correcciones sugeridas por grupo de fallo
  • ai-tickets.json — borradores de tickets compatibles con Jira
  • ai-failures-grouped.json — fallos agrupados por causa raíz

Licencia

MIT