- Home
- Skills
- Frontend & Web Apps
- PWA Manifest and Service Worker Check
More screenshots
Works with the AI Agents you already use
PWA Manifest and Service Worker Check
One trailing comma in manifest.webmanifest and browsers treat your app as having no manifest at all: no name, no icons, no install prompt.
$5
PWA Manifest and Service Worker Check
Example session with this skill installed
Check this project with pwa-manifest-sw-check.
- Read your context and instructions
- Compiled the pwa manifest
- Generated the UI component
$ python3 scripts/check_pwa.py examples/risky
BLOCK notes/js/sw.js:2 W04 IMPORTSCRIPTS_WILL_FAIL
importScripts('http://cdn.example.com/idb-keyval/6.2.1/umd.js');
Why: importScripts() loads a script over http:// (blocked as mixed content in a service worker served over HTTPS, so the worker does not start), or is called inside a fetch, message, push or other event handler. importScripts() works only while the worker script first runs or inside the install handler (Chrome 71+ and other browsers); later calls throw unless that same URL was already imported then.
Safer: Call importScripts() at the top level of the service worker with https:// or same-origin URLs, or bundle the code with ES module imports.
BLOCK notes/js/sw.js:11 W06 ADDALL_DUPLICATE_URL
BLOCK notes/js/sw.js:20 W05 EVENT_HANDLED_TOO_LATE
BLOCK notes/js/sw.js:30 W04 IMPORTSCRIPTS_WILL_FAIL
BLOCK notes/manifest.webmanifest:4 W02 START_URL_OR_SCOPE_IGNORED
BLOCK shop/public/site.webmanifest:6 W01 MANIFEST_NOT_VALID_JSON
BLOCK shop/vite.config.js:23 W03 PRIVATE_RESPONSES_CACHED
REVIEW notes/index.html:15 W19 SW_SCOPE_MISMATCH
REVIEW notes/js/sw.js:15 W15 OLD_CACHES_NEVER_DELETED
REVIEW notes/js/sw.js:21 W14 HTML_CACHE_FIRST
REVIEW notes/js/sw.js:22 W18 CACHES_EVERY_RESPONSE
REVIEW notes/manifest.webmanifest:1 W13 MANIFEST_WITHOUT_ID
REVIEW notes/manifest.webmanifest:9 W11 NOT_INSTALLABLE
REVIEW notes/manifest.webmanifest:10 W12 NO_MASKABLE_ICON
REVIEW shop/vite.config.js:8 W13 MANIFEST_WITHOUT_ID
REVIEW shop/vite.config.js:19 W16 SKIP_WAITING_WITH_PRECACHE
REVIEW shop/vite.config.js:28 W17 API_OR_SESSION_RESPONSES_CACHED
(Each finding also has Why and Safer lines, as in the first one.)
Verdict: BLOCK. Checked 5 files, 5 with PWA content.
This is a static check of file text. NOT FLAGGED is not a guarantee.
index.html
TSX · React component
Example file from a real run - the skill writes it into your workspace.
Connects securely to your tools. The creator never sees your data.
About this skill
One trailing comma in manifest.webmanifest and browsers treat your app as having no manifest at all: no name, no icons, no install prompt. A Workbox route that serves /api/account with StaleWhileRevalidate keeps one customer's account data on a shared computer after they sign out, because the Cache API ignores Cache-Control: private. An event.respondWith() placed after an await throws, and the request goes to the network as if the worker did not exist. This skill finds those and the other PWA mistakes listed below before you ship, and tells you how to fix each one.
Your agent runs a scanner on your web app manifests (manifest.json, *.webmanifest, Next.js app/manifest.ts, the manifest in vite-plugin-pwa configs), service workers (hand-written, Workbox, Serwist), Workbox runtimeCaching configs (workbox-config.js, vite-plugin-pwa, next-pwa, webpack), Angular ngsw-config.json and service worker registration calls. It parses manifests as strict JSON the way browsers do, reads JavaScript and TypeScript with comments and strings set aside, matches whole URL path segments (so /api/session is private and /api/sessions, a conference schedule, is not), understands Workbox matchers that exclude URLs (if ... return false, a NavigationRoute denylist), and knows the defaults of vite-plugin-pwa and next-pwa. The service worker code of the Workbox, Create React App, vite-plugin-pwa and Serwist templates passes without findings. It never runs, builds or serves your app. It returns BLOCK, REVIEW, or NOT FLAGGED, with the file, line, reason, and a safer approach, and each rule links to the W3C, MDN, web.dev or Chrome documentation behind it. Secrets are never printed.
What it checks
BLOCK
- W01: a manifest that is not valid JSON (trailing comma, comment, single quotes), not an object, or saved as UTF-16
- W02: start_url outside scope (including "/app" with scope "/app/"), or start_url or scope on localhost
- W03: routes that answer session, token or sign-out URLs, or account, profile, cart or checkout data, from a stored copy while online
- W04: importScripts() over http://, or called inside a fetch, message or other event handler
- W05: event.respondWith() or the first event.waitUntil() called after an await or in a then() callback
- W06: the same URL twice in a cache.addAll() list, also written as ./index.html and index.html (the install fails)
REVIEW
- W11: manifests that Chromium will not offer to install (no name, no icon of 144px or more, a display mode that is not installable, prefer_related_applications)
- W12: no maskable icon, or icons with purpose "any maskable"
- W13: manifests without an id
- W14: pages or .html files served cache-first
- W15: versioned caches that are never deleted
- W16: unconditional skipWaiting() in a worker that precaches the app, including next-pwa's default
- W17: API responses served with CacheFirst, CacheOnly or StaleWhileRevalidate (and Angular dataGroups with the default performance strategy), and session or token URLs stored for offline use
- W18: fetch handlers that store every response with cache.put()
- W19: service worker registrations whose scope misses the app's pages or needs a Service-Worker-Allowed header
What's included
- The scanner (Python 3.9+, standard library only)
- A rules guide with the reason, safer approach and official source link for each rule
- A risky and a safe example project (a static site with a hand-written service worker and a Vite shop with vite-plugin-pwa), and the real report the scanner produces on the risky one
Limits It reads file text and follows only a few facts across files (manifests linked from pages, a Service-Worker-Allowed header in server configs, vite-plugin-pwa autoUpdate). Matchers defined in another file, minified or generated service workers, icon files, HTTPS and the HTTP headers your server sends are not checked, and caching of private URLs in hand-written fetch handlers is reported only as cache-first or cache-everything findings. vite-plugin-pwa's autoUpdate mode and Serwist's template, which choose immediate updates on purpose, are not reported by W16. NOT FLAGGED is not a guarantee.
Static check of manifest, service worker and config text. Runtime behaviour, server headers and what browsers actually cached are not measured. NOT FLAGGED is not a guarantee.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before any payment.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 4 days ago
Permissions
Runs one local Python script in the terminal. It reads your project's files, writes nothing, and makes no network calls. The example project contains service worker code and configs with fake example.com URLs. Nothing in it is run.