> PWA with Workbox
Production-grade PWA caching with Google Workbox and Vite PWA plugin.
fetch
$
curl "https://skillshub.wtf/skillshub-team/catalog-batch5/pwa-workbox?format=md"SKILL.md•PWA with Workbox
Workbox PWA
Vite PWA Plugin
npm install vite-plugin-pwa
import { VitePWA } from 'vite-plugin-pwa';
export default defineConfig({
plugins: [VitePWA({
registerType: 'autoUpdate',
workbox: {
globPatterns: ['**/*.{js,css,html,ico,png,svg,woff2}'],
runtimeCaching: [
{ urlPattern: /^https:\/\/api\./, handler: 'NetworkFirst',
options: { cacheName: 'api', expiration: { maxEntries: 50, maxAgeSeconds: 300 } } },
{ urlPattern: /\.(?:png|jpg|svg|webp)$/, handler: 'CacheFirst',
options: { cacheName: 'images', expiration: { maxEntries: 100 } } },
],
},
})],
});
Workbox Strategies: CacheFirst, NetworkFirst, StaleWhileRevalidate, NetworkOnly, CacheOnly
Background Sync for offline form submissions
Precaching for app shell
> related_skills --same-repo
> Nix Dev Shells with direnv
Auto-activate reproducible dev environments with Nix flakes and direnv.
> Dagger with GitHub Actions
Run Dagger CI/CD pipelines in GitHub Actions for portable, testable builds.
> Bun + Hono API
Build fast APIs with Bun runtime and Hono framework.
> Deno Fresh Framework
Build full-stack web apps with Fresh on Deno. Islands, routes, and zero runtime overhead.
┌ stats
installs/wk0
░░░░░░░░░░first seenMar 18, 2026
└────────────