elhanafim/wallstreet-morocco/progressive-web-app
Claude Code and agent skill by elhanafim/wallstreet-morocco
- community
Checking that the SKILL.md file is still in the repository.
Build Progressive Web Apps (PWAs) with offline support, installability, and caching strategies. Trigger whenever the user mentions PWA, service workers, web app manifests, Workbox, 'add to home screen', or wants their web app to work offline, feel native, or be installable.
Install
npx vskill@latest install elhanafim/wallstreet-morocco/progressive-web-appSKILL.md
The same SKILL.md was published earlier as davila7/claude-code-templates/progressive-web-app.
Progressive Web Apps (PWAs)
Overview
A Progressive Web App is a web application that uses modern browser capabilities to deliver a fast, reliable, and installable experience — even on unreliable networks. The three required pillars are:
- HTTPS — Required in production for service workers to register (localhost is exempt for development).
- Web App Manifest (
manifest.json) — Makes the app installable and defines its appearance on device home screens. - Service Worker (
sw.js) — A background script that intercepts network requests, manages caches, and enables offline functionality.
When to Use This Skill
- Use when the user wants their web app to work offline or on unreliable networks.
- Use when building a mobile-first web project where users should be able to install the app to their home screen.
- Use when the user asks about caching strategies, service workers, or improving web app performance and resilience.
- Use when the user mentions Workbox, web app manifests, background sync, or push notifications for the web.
- Use when the user asks "can my website be installed like an app?" or "how do I make my site work offline?" — even if they don't use the word PWA.
Deliverables Checklist
Every PWA implementation must include these files at minimum:
- [ ]
index.html— Links manifest, registers service worker - [ ]
manifest.json— Full app metadata and icon set - [ ]
sw.js— Service worker with install, activate, and fetch handlers - [ ]
app.js— Main app logic with SW registration and install prompt handling - [ ]
offline.html— Fallback page shown when navigation fails offline (required — missing file will cause install to fail)
Step 1: Web App Manifest (manifest.json)
Defines how the app appears when installed. Must be linked from <head> via <link rel="manifest">.
Key fields:
display:standalonehides browser UI;minimal-uishows minimal controls;browseris standard tab.purpose: "maskable"on icons enables adaptive icons on Android (safe zone matters — keep content in center 80%).screenshotsis optional but required for Chrome's enhanced install dialog on desktop.
Step 2: HTML Shell (index.html)
Step 3: Service Worker Registration & Install Prompt (app.js)
Step 4: Service Worker (sw.js)
Cache Versioning (critical — always increment on deploy)
Install — Pre-cache the App Shell
Activate — Clean Up Old Caches
Fetch — Caching Strategies
Choose the right strategy per resource type:
Edge Cases & Platform Notes
iOS / Safari Quirks
- Safari supports manifests and service workers but does not support `beforeinstallprompt` — users must install via the Share → "Add to Home Screen" menu manually.
- Use the
apple-mobile-web-app-*meta tags (shown inindex.htmlabove) for proper iOS integration. - Safari may clear service worker caches after ~7 days of inactivity (Intelligent Tracking Prevention).
HTTPS Requirement
- Service workers only register on
https://origins.http://localhostis the only exception for development. - Use a tool like
mkcertorngrokif you need HTTPS locally with a custom hostname.
Cache-Busting on Deploy
- Always increment
CACHE_VERSIONinsw.jswhen deploying new assets. This ensures activate clears old caches and users get fresh files. - A common pattern is to inject the version automatically via your build tool (e.g., Vite, Webpack).
Opaque Responses (cross-origin requests)
- Requests to external origins (e.g., CDN fonts, third-party APIs) return "opaque" responses that cannot be inspected. Cache them with caution — a failed opaque response still gets a
200status. - Prefer
staleWhileRevalidatefor cross-origin resources, or use a library like Workbox which handles this safely.
Workbox (Optional: Production Shortcut)
For production apps, consider Workbox (Google's PWA library) instead of hand-rolling strategies. It handles edge cases, cache expiry, and versioning automatically.
Checklist Before Shipping
- [ ] Site is served over HTTPS
- [ ]
manifest.jsonhasname,short_name,start_url,display,icons(192 + 512) - [ ] Icons have
purpose: "any maskable" - [ ]
sw.jsregisters without errors in DevTools → Application → Service Workers - [ ] App shell loads from cache when network is throttled to "Offline" in DevTools
- [ ]
offline.htmlfallback is cached and served when navigation fails offline - [ ] Lighthouse PWA audit passes (Chrome DevTools → Lighthouse tab)
- [ ] Tested on iOS Safari (manual install flow) and Android Chrome (install prompt)
Security
- Security scanPassed, 96 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/plugins/antigravity-awesome-skills/skills/progressive-web-app/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/elhanafim/wallstreet-morocco/progressive-web-app)