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

generator-jhipster-playwright

v1.2.0

Published

JHipster Playwright E2E blueprint - replaces Cypress with Playwright for end-to-end testing

Downloads

340

Readme

generator-jhipster-playwright

CI npm version

A JHipster blueprint that replaces the generated Cypress end-to-end suite with Playwright.

Introduction

This is a JHipster blueprint. It overrides the cypress sub-generator and writes Playwright files instead of Cypress files for generated applications.

Supported Matrix

| Framework | JWT | Session | OAuth2 | |-----------|-----|---------|--------| | React | Yes | Yes | Yes | | Angular | Yes | Yes | Yes | | Vue | Yes | Yes | Yes |

All 9 combinations are verified in CI against freshly generated JHipster applications. OAuth2 tests run against a Keycloak instance.

Installation

npm install -g [email protected]
npm install -g generator-jhipster-playwright

Usage

How to Generate Code

This package exposes a dedicated CLI:

jhipster-playwright

It can also be used through the standard JHipster CLI:

jhipster --blueprints playwright

For available options, you can run:

jhipster-playwright app --help

Enable the Cypress Test Framework

This blueprint overrides JHipster's cypress sub-generator. Upstream JHipster only composes that generator when testFrameworks includes cypress, so Playwright generation must be triggered with Cypress selected.

Use one of these approaches:

jhipster --blueprints playwright --test-frameworks cypress
jhipster-playwright --test-frameworks cypress
jhipster jdl app.jdl --blueprints playwright --test-frameworks cypress

You can also express this directly in JDL:

application {
  config {
    baseName myApp
    clientFramework react
    authenticationType jwt
    testFrameworks [cypress]
  }
}

How to Run the Generated Tests

jhipster jdl app.jdl --blueprints playwright --test-frameworks cypress --skip-install --force

After generation, install dependencies, install the Playwright browser, start the backend, and run the suite:

npm install
npx playwright install chromium
./mvnw

In a second terminal:

npx playwright test

The generated playwright.config.ts starts the frontend dev server automatically. The Spring Boot backend still needs to be running before the tests execute.

For OAuth2 applications, a Keycloak instance must be running before the backend starts:

docker compose -f src/main/docker/keycloak.yml up -d

Generated Output

The blueprint writes:

  • playwright.config.ts
  • Playwright support utilities under src/test/javascript/playwright/support
  • Account, administration, and entity specs under src/test/javascript/playwright/e2e
  • @playwright/test and Playwright npm scripts in the generated application's package.json

For Angular applications, the blueprint also adds @popperjs/core to the generated app dependencies so the generated frontend has the required Popper peer dependency available.

For Angular session-auth applications, a custom proxy.config.playwright.mjs is generated to avoid proxying lazy-loaded route chunks.

Local Development

To work on the blueprint locally:

npm install
npm test
npm pack --dry-run --cache ./.npm-cache

To exercise the blueprint locally against a generated app, link it first:

npm link

Then in the target app directory:

npm link generator-jhipster-playwright
jhipster --blueprints playwright --test-frameworks cypress --skip-install --force

Updated generator-jhipster

This blueprint currently targets generator-jhipster 9.0.0.

If you want to run it through the standard JHipster CLI, install a compatible JHipster version and use:

npm install -g [email protected]
jhipster --blueprints playwright --test-frameworks cypress

License

Apache 2.0, see LICENSE.