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

pwa-starter

v1.2.3

Published

Instantly scaffold a Progressive Web App with HTML, CSS, manifest, service worker, and install button — zero config

Readme

pwa-starter

Instantly scaffold a Progressive Web App with a single command — zero config, zero dependencies.

npx pwa-starter

What is a PWA?

A Progressive Web App (PWA) is a website that can be installed on any device (phone, tablet, desktop) and works offline. It uses a Service Worker to cache files and a Manifest to define how the app looks when installed.

pwa-starter generates everything you need to make that happen — including an Install App button that your users can click to install your app directly from the browser.


Features

| Feature | Description | | --- | --- | | 📄 index.html | Complete HTML page with meta tags, install button, and service worker registration | | 🎨 style.css | Modern dark theme with CSS variables and gradient accents | | 📦 manifest.json | PWA manifest with app name, theme color, and icon references | | ⚙️ service-worker.js | Caches your app for offline use with cache versioning | | 📲 Install Button | Built-in "Install App" button using the beforeinstallprompt API |


Quick Start

1. Create a new folder and run the tool

mkdir my-app
cd my-app
npx pwa-starter

2. Add your icons

Create two PNG icon files in the same folder:

  • icon-192.png — 192×192 pixels
  • icon-512.png — 512×512 pixels

Tip: Use favicon.io or realfavicongenerator.net to generate icons from text or an image.

3. Serve it locally

npx serve

Open the URL shown in your terminal (usually http://localhost:3000).

Note: PWA features (install button, offline mode) only work when served over HTTPS or on localhost.


Generated File Structure

my-app/
├── index.html          ← Main page with install button
├── style.css           ← Dark theme styles
├── manifest.json       ← PWA configuration
├── service-worker.js   ← Offline caching logic
├── icon-192.png        ← (you add this)
└── icon-512.png        ← (you add this)

How the Install Button Works

The generated index.html includes a hidden "Install App" button. Here's how it works:

  1. When a browser detects your app meets PWA criteria, it fires a beforeinstallprompt event.
  2. The JavaScript captures this event and shows the install button.
  3. When the user clicks the button, it triggers the browser's native install dialog.
  4. After installation, the button hides itself.

PWA install criteria:

  • Served over HTTPS (or localhost)
  • Has a valid manifest.json with name, icons, start_url, and display
  • Has a registered Service Worker

Testing Your Published Package

After publishing, test it works for others:

mkdir test-pwa
cd test-pwa
npx pwa-starter
npx serve

Open the browser and verify:

  • ✅ Page loads with dark theme
  • ✅ Service Worker registers (check DevTools → Application → Service Workers)
  • ✅ Install button appears (on supported browsers when served via localhost)

License

MIT © VR