[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6DZ28D9T2A7PCYB76SJQ7N0":3,"skill-same:01M6DZ28D9T2A7PCYB76SJQ7N0":69},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":34,"linkOnly":35,"markdownContent":36,"markdownBody":37,"frontMatter":38,"refName":42,"commitSha":43,"skillDirectory":44,"forksCount":45,"repositoryHtmlUrl":46,"repositoryHomepageUrl":6,"ownerHtmlUrl":47,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":48,"install":49,"resources":62},"01M6DZ28D9T2A7PCYB76SJQ7N0","performance",null,"Optimize web performance for faster loading and better user experience. Use when asked to \"speed up my site\", \"optimize performance\", \"reduce load time\", \"fix slow loading\", \"improve page speed\", or \"performance audit\".","kennyolofsson23-netizen\u002Fclaude-code-config","kennyolofsson23-netizen","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F262391667?v=4","01M6DYPCT5DBDV0C11CXD8G7RX","01M6DYPD3KYJ7P6A8H7RKJ6KGG",0,"MIT","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Fperformance\u002FSKILL.md",[],[5,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33],"user","optimize web","user experience","speed","time","optimize","up","use","fix","quality","page","site","improve","audit","web performance","web","2026-11-10 10:12:30",false,"---\nname: performance\ndescription: Optimize web performance for faster loading and better user experience. Use when asked to \"speed up my site\", \"optimize performance\", \"reduce load time\", \"fix slow loading\", \"improve page speed\", or \"performance audit\".\nlicense: MIT\nmetadata:\n  author: web-quality-skills\n  version: \"1.0\"\n---\n\n# Performance optimization\n\nDeep performance optimization based on Lighthouse performance audits. Focuses on loading speed, runtime efficiency, and resource optimization.\n\n## How it works\n\n1. Identify performance bottlenecks in code and assets\n2. Prioritize by impact on Core Web Vitals\n3. Provide specific optimizations with code examples\n4. Measure improvement with before\u002Fafter metrics\n\n## Performance budget\n\n| Resource | Budget | Rationale |\n|----------|--------|-----------|\n| Total page weight | \u003C 1.5 MB | 3G loads in ~4s |\n| JavaScript (compressed) | \u003C 300 KB | Parsing + execution time |\n| CSS (compressed) | \u003C 100 KB | Render blocking |\n| Images (above-fold) | \u003C 500 KB | LCP impact |\n| Fonts | \u003C 100 KB | FOIT\u002FFOUT prevention |\n| Third-party | \u003C 200 KB | Uncontrolled latency |\n\n## Critical rendering path\n\n### Server response\n* **TTFB \u003C 800ms.** Time to First Byte should be fast. Use CDN, caching, and efficient backends.\n* **Enable compression.** Gzip or Brotli for text assets. Brotli preferred (15-20% smaller).\n* **HTTP\u002F2 or HTTP\u002F3.** Multiplexing reduces connection overhead.\n* **Edge caching.** Cache HTML at CDN edge when possible.\n\n### Resource loading\n\n**Preconnect to required origins:**\n```html\n\u003Clink rel=\"preconnect\" href=\"https:\u002F\u002Ffonts.googleapis.com\">\n\u003Clink rel=\"preconnect\" href=\"https:\u002F\u002Fcdn.example.com\" crossorigin>\n```\n\n**Preload critical resources:**\n```html\n\u003C!-- LCP image -->\n\u003Clink rel=\"preload\" href=\"\u002Fhero.webp\" as=\"image\" fetchpriority=\"high\">\n\n\u003C!-- Critical font -->\n\u003Clink rel=\"preload\" href=\"\u002Ffont.woff2\" as=\"font\" type=\"font\u002Fwoff2\" crossorigin>\n```\n\n**Defer non-critical CSS:**\n```html\n\u003C!-- Critical CSS inlined -->\n\u003Cstyle>\u002F* Above-fold styles *\u002F\u003C\u002Fstyle>\n\n\u003C!-- Non-critical CSS -->\n\u003Clink rel=\"preload\" href=\"\u002Fstyles.css\" as=\"style\" onload=\"this.onload=null;this.rel='stylesheet'\">\n\u003Cnoscript>\u003Clink rel=\"stylesheet\" href=\"\u002Fstyles.css\">\u003C\u002Fnoscript>\n```\n\n### JavaScript optimization\n\n**Defer non-essential scripts:**\n```html\n\u003C!-- Parser-blocking (avoid) -->\n\u003Cscript src=\"\u002Fcritical.js\">\u003C\u002Fscript>\n\n\u003C!-- Deferred (preferred) -->\n\u003Cscript defer src=\"\u002Fapp.js\">\u003C\u002Fscript>\n\n\u003C!-- Async (for independent scripts) -->\n\u003Cscript async src=\"\u002Fanalytics.js\">\u003C\u002Fscript>\n\n\u003C!-- Module (deferred by default) -->\n\u003Cscript type=\"module\" src=\"\u002Fapp.mjs\">\u003C\u002Fscript>\n```\n\n**Code splitting patterns:**\n```javascript\n\u002F\u002F Route-based splitting\nconst Dashboard = lazy(() => import('.\u002FDashboard'));\n\n\u002F\u002F Component-based splitting\nconst HeavyChart = lazy(() => import('.\u002FHeavyChart'));\n\n\u002F\u002F Feature-based splitting\nif (user.isPremium) {\n  const PremiumFeatures = await import('.\u002FPremiumFeatures');\n}\n```\n\n**Tree shaking best practices:**\n```javascript\n\u002F\u002F ❌ Imports entire library\nimport _ from 'lodash';\n_.debounce(fn, 300);\n\n\u002F\u002F ✅ Imports only what's needed\nimport debounce from 'lodash\u002Fdebounce';\ndebounce(fn, 300);\n```\n\n## Image optimization\n\n### Format selection\n| Format | Use case | Browser support |\n|--------|----------|-----------------|\n| AVIF | Photos, best compression | 92%+ |\n| WebP | Photos, good fallback | 97%+ |\n| PNG | Graphics with transparency | Universal |\n| SVG | Icons, logos, illustrations | Universal |\n\n### Responsive images\n```html\n\u003Cpicture>\n  \u003C!-- AVIF for modern browsers -->\n  \u003Csource \n    type=\"image\u002Favif\"\n    srcset=\"hero-400.avif 400w,\n            hero-800.avif 800w,\n            hero-1200.avif 1200w\"\n    sizes=\"(max-width: 600px) 100vw, 50vw\">\n  \n  \u003C!-- WebP fallback -->\n  \u003Csource \n    type=\"image\u002Fwebp\"\n    srcset=\"hero-400.webp 400w,\n            hero-800.webp 800w,\n            hero-1200.webp 1200w\"\n    sizes=\"(max-width: 600px) 100vw, 50vw\">\n  \n  \u003C!-- JPEG fallback -->\n  \u003Cimg \n    src=\"hero-800.jpg\"\n    srcset=\"hero-400.jpg 400w,\n            hero-800.jpg 800w,\n            hero-1200.jpg 1200w\"\n    sizes=\"(max-width: 600px) 100vw, 50vw\"\n    width=\"1200\" \n    height=\"600\"\n    alt=\"Hero image\"\n    loading=\"lazy\"\n    decoding=\"async\">\n\u003C\u002Fpicture>\n```\n\n### LCP image priority\n```html\n\u003C!-- Above-fold LCP image: eager loading, high priority -->\n\u003Cimg \n  src=\"hero.webp\" \n  fetchpriority=\"high\"\n  loading=\"eager\"\n  decoding=\"sync\"\n  alt=\"Hero\">\n\n\u003C!-- Below-fold images: lazy loading -->\n\u003Cimg \n  src=\"product.webp\" \n  loading=\"lazy\"\n  decoding=\"async\"\n  alt=\"Product\">\n```\n\n## Font optimization\n\n### Loading strategy\n```css\n\u002F* System font stack as fallback *\u002F\nbody {\n  font-family: 'Custom Font', -apple-system, BlinkMacSystemFont, \n               'Segoe UI', Roboto, sans-serif;\n}\n\n\u002F* Prevent invisible text *\u002F\n@font-face {\n  font-family: 'Custom Font';\n  src: url('\u002Ffonts\u002Fcustom.woff2') format('woff2');\n  font-display: swap; \u002F* or optional for non-critical *\u002F\n  font-weight: 400;\n  font-style: normal;\n  unicode-range: U+0000-00FF; \u002F* Subset to Latin *\u002F\n}\n```\n\n### Preloading critical fonts\n```html\n\u003Clink rel=\"preload\" href=\"\u002Ffonts\u002Fheading.woff2\" as=\"font\" type=\"font\u002Fwoff2\" crossorigin>\n```\n\n### Variable fonts\n```css\n\u002F* One file instead of multiple weights *\u002F\n@font-face {\n  font-family: 'Inter';\n  src: url('\u002Ffonts\u002FInter-Variable.woff2') format('woff2-variations');\n  font-weight: 100 900;\n  font-display: swap;\n}\n```\n\n## Caching strategy\n\n### Cache-Control headers\n```\n# HTML (short or no cache)\nCache-Control: no-cache, must-revalidate\n\n# Static assets with hash (immutable)\nCache-Control: public, max-age=31536000, immutable\n\n# Static assets without hash\nCache-Control: public, max-age=86400, stale-while-revalidate=604800\n\n# API responses\nCache-Control: private, max-age=0, must-revalidate\n```\n\n### Service worker caching\n```javascript\n\u002F\u002F Cache-first for static assets\nself.addEventListener('fetch', (event) => {\n  if (event.request.destination === 'image' ||\n      event.request.destination === 'style' ||\n      event.request.destination === 'script') {\n    event.respondWith(\n      caches.match(event.request).then((cached) => {\n        return cached || fetch(event.request).then((response) => {\n          const clone = response.clone();\n          caches.open('static-v1').then((cache) => cache.put(event.request, clone));\n          return response;\n        });\n      })\n    );\n  }\n});\n```\n\n## Runtime performance\n\n### Avoid layout thrashing\n```javascript\n\u002F\u002F ❌ Forces multiple reflows\nelements.forEach(el => {\n  const height = el.offsetHeight; \u002F\u002F Read\n  el.style.height = height + 10 + 'px'; \u002F\u002F Write\n});\n\n\u002F\u002F ✅ Batch reads, then batch writes\nconst heights = elements.map(el => el.offsetHeight); \u002F\u002F All reads\nelements.forEach((el, i) => {\n  el.style.height = heights[i] + 10 + 'px'; \u002F\u002F All writes\n});\n```\n\n### Debounce expensive operations\n```javascript\nfunction debounce(fn, delay) {\n  let timeout;\n  return (...args) => {\n    clearTimeout(timeout);\n    timeout = setTimeout(() => fn(...args), delay);\n  };\n}\n\n\u002F\u002F Debounce scroll\u002Fresize handlers\nwindow.addEventListener('scroll', debounce(handleScroll, 100));\n```\n\n### Use requestAnimationFrame\n```javascript\n\u002F\u002F ❌ May cause jank\nsetInterval(animate, 16);\n\n\u002F\u002F ✅ Synced with display refresh\nfunction animate() {\n  \u002F\u002F Animation logic\n  requestAnimationFrame(animate);\n}\nrequestAnimationFrame(animate);\n```\n\n### Virtualize long lists\n```javascript\n\u002F\u002F For lists > 100 items, render only visible items\n\u002F\u002F Use libraries like react-window, vue-virtual-scroller, or native CSS:\n.virtual-list {\n  content-visibility: auto;\n  contain-intrinsic-size: 0 50px; \u002F* Estimated item height *\u002F\n}\n```\n\n## Third-party scripts\n\n### Load strategies\n```javascript\n\u002F\u002F ❌ Blocks main thread\n\u003Cscript src=\"https:\u002F\u002Fanalytics.example.com\u002Fscript.js\">\u003C\u002Fscript>\n\n\u002F\u002F ✅ Async loading\n\u003Cscript async src=\"https:\u002F\u002Fanalytics.example.com\u002Fscript.js\">\u003C\u002Fscript>\n\n\u002F\u002F ✅ Delay until interaction\n\u003Cscript>\ndocument.addEventListener('DOMContentLoaded', () => {\n  const observer = new IntersectionObserver((entries) => {\n    if (entries[0].isIntersecting) {\n      const script = document.createElement('script');\n      script.src = 'https:\u002F\u002Fwidget.example.com\u002Fembed.js';\n      document.body.appendChild(script);\n      observer.disconnect();\n    }\n  });\n  observer.observe(document.querySelector('#widget-container'));\n});\n\u003C\u002Fscript>\n```\n\n### Facade pattern\n```html\n\u003C!-- Show static placeholder until interaction -->\n\u003Cdiv class=\"youtube-facade\" \n     data-video-id=\"abc123\" \n     onclick=\"loadYouTube(this)\">\n  \u003Cimg src=\"\u002Fthumbnails\u002Fabc123.jpg\" alt=\"Video title\">\n  \u003Cbutton aria-label=\"Play video\">▶\u003C\u002Fbutton>\n\u003C\u002Fdiv>\n```\n\n## Measurement\n\n### Key metrics\n| Metric | Target | Tool |\n|--------|--------|------|\n| LCP | \u003C 2.5s | Lighthouse, CrUX |\n| FCP | \u003C 1.8s | Lighthouse |\n| Speed Index | \u003C 3.4s | Lighthouse |\n| TBT | \u003C 200ms | Lighthouse |\n| TTI | \u003C 3.8s | Lighthouse |\n\n### Testing commands\n```bash\n# Lighthouse CLI\nnpx lighthouse https:\u002F\u002Fexample.com --output html --output-path report.html\n\n# Web Vitals library\nimport {onLCP, onINP, onCLS} from 'web-vitals';\nonLCP(console.log);\nonINP(console.log);\nonCLS(console.log);\n```\n\n## References\n\nFor Core Web Vitals specific optimizations, see [Core Web Vitals](..\u002Fcore-web-vitals\u002FSKILL.md).\n","# Performance optimization\n\nDeep performance optimization based on Lighthouse performance audits. Focuses on loading speed, runtime efficiency, and resource optimization.\n\n## How it works\n\n1. Identify performance bottlenecks in code and assets\n2. Prioritize by impact on Core Web Vitals\n3. Provide specific optimizations with code examples\n4. Measure improvement with before\u002Fafter metrics\n\n## Performance budget\n\n| Resource | Budget | Rationale |\n|----------|--------|-----------|\n| Total page weight | \u003C 1.5 MB | 3G loads in ~4s |\n| JavaScript (compressed) | \u003C 300 KB | Parsing + execution time |\n| CSS (compressed) | \u003C 100 KB | Render blocking |\n| Images (above-fold) | \u003C 500 KB | LCP impact |\n| Fonts | \u003C 100 KB | FOIT\u002FFOUT prevention |\n| Third-party | \u003C 200 KB | Uncontrolled latency |\n\n## Critical rendering path\n\n### Server response\n* **TTFB \u003C 800ms.** Time to First Byte should be fast. Use CDN, caching, and efficient backends.\n* **Enable compression.** Gzip or Brotli for text assets. Brotli preferred (15-20% smaller).\n* **HTTP\u002F2 or HTTP\u002F3.** Multiplexing reduces connection overhead.\n* **Edge caching.** Cache HTML at CDN edge when possible.\n\n### Resource loading\n\n**Preconnect to required origins:**\n```html\n\u003Clink rel=\"preconnect\" href=\"https:\u002F\u002Ffonts.googleapis.com\">\n\u003Clink rel=\"preconnect\" href=\"https:\u002F\u002Fcdn.example.com\" crossorigin>\n```\n\n**Preload critical resources:**\n```html\n\u003C!-- LCP image -->\n\u003Clink rel=\"preload\" href=\"\u002Fhero.webp\" as=\"image\" fetchpriority=\"high\">\n\n\u003C!-- Critical font -->\n\u003Clink rel=\"preload\" href=\"\u002Ffont.woff2\" as=\"font\" type=\"font\u002Fwoff2\" crossorigin>\n```\n\n**Defer non-critical CSS:**\n```html\n\u003C!-- Critical CSS inlined -->\n\u003Cstyle>\u002F* Above-fold styles *\u002F\u003C\u002Fstyle>\n\n\u003C!-- Non-critical CSS -->\n\u003Clink rel=\"preload\" href=\"\u002Fstyles.css\" as=\"style\" onload=\"this.onload=null;this.rel='stylesheet'\">\n\u003Cnoscript>\u003Clink rel=\"stylesheet\" href=\"\u002Fstyles.css\">\u003C\u002Fnoscript>\n```\n\n### JavaScript optimization\n\n**Defer non-essential scripts:**\n```html\n\u003C!-- Parser-blocking (avoid) -->\n\u003Cscript src=\"\u002Fcritical.js\">\u003C\u002Fscript>\n\n\u003C!-- Deferred (preferred) -->\n\u003Cscript defer src=\"\u002Fapp.js\">\u003C\u002Fscript>\n\n\u003C!-- Async (for independent scripts) -->\n\u003Cscript async src=\"\u002Fanalytics.js\">\u003C\u002Fscript>\n\n\u003C!-- Module (deferred by default) -->\n\u003Cscript type=\"module\" src=\"\u002Fapp.mjs\">\u003C\u002Fscript>\n```\n\n**Code splitting patterns:**\n```javascript\n\u002F\u002F Route-based splitting\nconst Dashboard = lazy(() => import('.\u002FDashboard'));\n\n\u002F\u002F Component-based splitting\nconst HeavyChart = lazy(() => import('.\u002FHeavyChart'));\n\n\u002F\u002F Feature-based splitting\nif (user.isPremium) {\n  const PremiumFeatures = await import('.\u002FPremiumFeatures');\n}\n```\n\n**Tree shaking best practices:**\n```javascript\n\u002F\u002F ❌ Imports entire library\nimport _ from 'lodash';\n_.debounce(fn, 300);\n\n\u002F\u002F ✅ Imports only what's needed\nimport debounce from 'lodash\u002Fdebounce';\ndebounce(fn, 300);\n```\n\n## Image optimization\n\n### Format selection\n| Format | Use case | Browser support |\n|--------|----------|-----------------|\n| AVIF | Photos, best compression | 92%+ |\n| WebP | Photos, good fallback | 97%+ |\n| PNG | Graphics with transparency | Universal |\n| SVG | Icons, logos, illustrations | Universal |\n\n### Responsive images\n```html\n\u003Cpicture>\n  \u003C!-- AVIF for modern browsers -->\n  \u003Csource \n    type=\"image\u002Favif\"\n    srcset=\"hero-400.avif 400w,\n            hero-800.avif 800w,\n            hero-1200.avif 1200w\"\n    sizes=\"(max-width: 600px) 100vw, 50vw\">\n  \n  \u003C!-- WebP fallback -->\n  \u003Csource \n    type=\"image\u002Fwebp\"\n    srcset=\"hero-400.webp 400w,\n            hero-800.webp 800w,\n            hero-1200.webp 1200w\"\n    sizes=\"(max-width: 600px) 100vw, 50vw\">\n  \n  \u003C!-- JPEG fallback -->\n  \u003Cimg \n    src=\"hero-800.jpg\"\n    srcset=\"hero-400.jpg 400w,\n            hero-800.jpg 800w,\n            hero-1200.jpg 1200w\"\n    sizes=\"(max-width: 600px) 100vw, 50vw\"\n    width=\"1200\" \n    height=\"600\"\n    alt=\"Hero image\"\n    loading=\"lazy\"\n    decoding=\"async\">\n\u003C\u002Fpicture>\n```\n\n### LCP image priority\n```html\n\u003C!-- Above-fold LCP image: eager loading, high priority -->\n\u003Cimg \n  src=\"hero.webp\" \n  fetchpriority=\"high\"\n  loading=\"eager\"\n  decoding=\"sync\"\n  alt=\"Hero\">\n\n\u003C!-- Below-fold images: lazy loading -->\n\u003Cimg \n  src=\"product.webp\" \n  loading=\"lazy\"\n  decoding=\"async\"\n  alt=\"Product\">\n```\n\n## Font optimization\n\n### Loading strategy\n```css\n\u002F* System font stack as fallback *\u002F\nbody {\n  font-family: 'Custom Font', -apple-system, BlinkMacSystemFont, \n               'Segoe UI', Roboto, sans-serif;\n}\n\n\u002F* Prevent invisible text *\u002F\n@font-face {\n  font-family: 'Custom Font';\n  src: url('\u002Ffonts\u002Fcustom.woff2') format('woff2');\n  font-display: swap; \u002F* or optional for non-critical *\u002F\n  font-weight: 400;\n  font-style: normal;\n  unicode-range: U+0000-00FF; \u002F* Subset to Latin *\u002F\n}\n```\n\n### Preloading critical fonts\n```html\n\u003Clink rel=\"preload\" href=\"\u002Ffonts\u002Fheading.woff2\" as=\"font\" type=\"font\u002Fwoff2\" crossorigin>\n```\n\n### Variable fonts\n```css\n\u002F* One file instead of multiple weights *\u002F\n@font-face {\n  font-family: 'Inter';\n  src: url('\u002Ffonts\u002FInter-Variable.woff2') format('woff2-variations');\n  font-weight: 100 900;\n  font-display: swap;\n}\n```\n\n## Caching strategy\n\n### Cache-Control headers\n```\n# HTML (short or no cache)\nCache-Control: no-cache, must-revalidate\n\n# Static assets with hash (immutable)\nCache-Control: public, max-age=31536000, immutable\n\n# Static assets without hash\nCache-Control: public, max-age=86400, stale-while-revalidate=604800\n\n# API responses\nCache-Control: private, max-age=0, must-revalidate\n```\n\n### Service worker caching\n```javascript\n\u002F\u002F Cache-first for static assets\nself.addEventListener('fetch', (event) => {\n  if (event.request.destination === 'image' ||\n      event.request.destination === 'style' ||\n      event.request.destination === 'script') {\n    event.respondWith(\n      caches.match(event.request).then((cached) => {\n        return cached || fetch(event.request).then((response) => {\n          const clone = response.clone();\n          caches.open('static-v1').then((cache) => cache.put(event.request, clone));\n          return response;\n        });\n      })\n    );\n  }\n});\n```\n\n## Runtime performance\n\n### Avoid layout thrashing\n```javascript\n\u002F\u002F ❌ Forces multiple reflows\nelements.forEach(el => {\n  const height = el.offsetHeight; \u002F\u002F Read\n  el.style.height = height + 10 + 'px'; \u002F\u002F Write\n});\n\n\u002F\u002F ✅ Batch reads, then batch writes\nconst heights = elements.map(el => el.offsetHeight); \u002F\u002F All reads\nelements.forEach((el, i) => {\n  el.style.height = heights[i] + 10 + 'px'; \u002F\u002F All writes\n});\n```\n\n### Debounce expensive operations\n```javascript\nfunction debounce(fn, delay) {\n  let timeout;\n  return (...args) => {\n    clearTimeout(timeout);\n    timeout = setTimeout(() => fn(...args), delay);\n  };\n}\n\n\u002F\u002F Debounce scroll\u002Fresize handlers\nwindow.addEventListener('scroll', debounce(handleScroll, 100));\n```\n\n### Use requestAnimationFrame\n```javascript\n\u002F\u002F ❌ May cause jank\nsetInterval(animate, 16);\n\n\u002F\u002F ✅ Synced with display refresh\nfunction animate() {\n  \u002F\u002F Animation logic\n  requestAnimationFrame(animate);\n}\nrequestAnimationFrame(animate);\n```\n\n### Virtualize long lists\n```javascript\n\u002F\u002F For lists > 100 items, render only visible items\n\u002F\u002F Use libraries like react-window, vue-virtual-scroller, or native CSS:\n.virtual-list {\n  content-visibility: auto;\n  contain-intrinsic-size: 0 50px; \u002F* Estimated item height *\u002F\n}\n```\n\n## Third-party scripts\n\n### Load strategies\n```javascript\n\u002F\u002F ❌ Blocks main thread\n\u003Cscript src=\"https:\u002F\u002Fanalytics.example.com\u002Fscript.js\">\u003C\u002Fscript>\n\n\u002F\u002F ✅ Async loading\n\u003Cscript async src=\"https:\u002F\u002Fanalytics.example.com\u002Fscript.js\">\u003C\u002Fscript>\n\n\u002F\u002F ✅ Delay until interaction\n\u003Cscript>\ndocument.addEventListener('DOMContentLoaded', () => {\n  const observer = new IntersectionObserver((entries) => {\n    if (entries[0].isIntersecting) {\n      const script = document.createElement('script');\n      script.src = 'https:\u002F\u002Fwidget.example.com\u002Fembed.js';\n      document.body.appendChild(script);\n      observer.disconnect();\n    }\n  });\n  observer.observe(document.querySelector('#widget-container'));\n});\n\u003C\u002Fscript>\n```\n\n### Facade pattern\n```html\n\u003C!-- Show static placeholder until interaction -->\n\u003Cdiv class=\"youtube-facade\" \n     data-video-id=\"abc123\" \n     onclick=\"loadYouTube(this)\">\n  \u003Cimg src=\"\u002Fthumbnails\u002Fabc123.jpg\" alt=\"Video title\">\n  \u003Cbutton aria-label=\"Play video\">▶\u003C\u002Fbutton>\n\u003C\u002Fdiv>\n```\n\n## Measurement\n\n### Key metrics\n| Metric | Target | Tool |\n|--------|--------|------|\n| LCP | \u003C 2.5s | Lighthouse, CrUX |\n| FCP | \u003C 1.8s | Lighthouse |\n| Speed Index | \u003C 3.4s | Lighthouse |\n| TBT | \u003C 200ms | Lighthouse |\n| TTI | \u003C 3.8s | Lighthouse |\n\n### Testing commands\n```bash\n# Lighthouse CLI\nnpx lighthouse https:\u002F\u002Fexample.com --output html --output-path report.html\n\n# Web Vitals library\nimport {onLCP, onINP, onCLS} from 'web-vitals';\nonLCP(console.log);\nonINP(console.log);\nonCLS(console.log);\n```\n\n## References\n\nFor Core Web Vitals specific optimizations, see [Core Web Vitals](..\u002Fcore-web-vitals\u002FSKILL.md).\n",{"name":5,"license":14,"metadata":39,"description":7},{"author":40,"version":41},"web-quality-skills","1.0","main","770ead1d2718b931bf0d81b757d75d0f33e43d90","skills\u002Fperformance",2,"https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen","2026-09-05 20:20:54",{"source":8,"skillName":5,"commands":50,"prompt":60,"zipAvailable":61},[51,54,57],{"tool":52,"command":53},"npx","npx skills add kennyolofsson23-netizen\u002Fclaude-code-config --skill performance",{"tool":55,"command":56},"bunx","bunx skills add kennyolofsson23-netizen\u002Fclaude-code-config --skill performance",{"tool":58,"command":59},"pnpm","pnpm dlx skills add kennyolofsson23-netizen\u002Fclaude-code-config --skill performance","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Fperformance\u002FSKILL.md",true,[63],{"path":64,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":67,"sourceHtmlUrl":68},"agents\u002Fopenai.yaml","REFERENCE","参考文档",218,"https:\u002F\u002Fgithub.com\u002Fagency-black\u002FSkills\u002Fblob\u002Fmain\u002Fios-debugger-agent\u002Fagents\u002Fopenai.yaml",[70,96,128,162,179,205],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":74,"categories":75,"keywords":86,"publishedAt":34},"01M6DZ7A62MZTGTBH4GYQPYHHM","web-quality-audit","Comprehensive web quality audit covering performance, accessibility, SEO, and best practices. Use when asked to \"audit my site\", \"review web quality\", \"run lighthouse audit\", \"check page quality\", or \"optimize my website\".","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Fweb-quality-audit\u002FSKILL.md",[76,81],{"categoryNo":77,"categoryName":78,"taxonomyType":79,"taxonomyTypeDesc":80},"01JBSEEDCAT000000000000019","营销推广","SCENARIO","使用场景",{"categoryNo":82,"categoryName":83,"taxonomyType":84,"taxonomyTypeDesc":85},"01JBSEEDCAT000000000000035","市场营销","PROFESSION","适用职业",[33,31,87,27,88,5,89,90,91,92,93,94,29,28,95,25,23],"web quality audit","review","accessibility","run","best practices","website","seo","Lighthouse","check",{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":108,"publishedAt":34},"01M6DZ6385911YENGYA985W015","tailwind-v4-shadcn","Production-tested setup for Tailwind CSS v4 with shadcn\u002Fui, Vite, and React.\n\nUse when: initializing React projects with Tailwind v4, setting up shadcn\u002Fui,\nimplementing dark mode, debugging CSS variable issues, fixing theme switching,\nmigrating from Tailwind v3, or encountering color\u002Ftheming problems.\n\nCovers: @theme inline pattern, CSS variable architecture, dark mode with\nThemeProvider, component composition, vite.config setup, common v4 gotchas,\nand production-tested patterns.\n\nKeywords: Tailwind v4, shadcn\u002Fui, @tailwindcss\u002Fvite, @theme inline, dark mode,\nCSS variables, hsl() wrapper, components.json, React theming, theme switching,\ncolors not working, variables broken, theme not applying, @plugin directive,\ntypography plugin, forms plugin, prose class, @tailwindcss\u002Ftypography,\n@tailwindcss\u002Fforms","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Ftailwind-v4-shadcn\u002FSKILL.md",[102,105],{"categoryNo":103,"categoryName":104,"taxonomyType":79,"taxonomyTypeDesc":80},"01JBSEEDCAT000000000000009","前端开发",{"categoryNo":106,"categoryName":107,"taxonomyType":79,"taxonomyTypeDesc":80},"01JBSEEDCAT000000000000015","视觉设计",[109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,24,126,127],"shadcn","Tailwind","tailwind v4","tailwind v4 shadcn","css","tailwindcss","components","react","component","architecture","config","debugging","issues","Composition","projects","common","broken","switching","css variables",{"skillNo":129,"name":130,"nameZh":6,"description":131,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":132,"categories":133,"keywords":142,"publishedAt":34},"01M6DZ5Z3F0PTH87NM9ATQD3E3","social-content","When the user wants help creating, scheduling, or optimizing social media content for LinkedIn, Twitter\u002FX, Instagram, TikTok, Facebook, or other platforms. Also use when the user mentions 'LinkedIn post,' 'Twitter thread,' 'social media,' 'content calendar,' 'social scheduling,' 'engagement,' or 'viral content.' This skill covers content creation, repurposing, and platform-specific strategies.","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Fsocial-content\u002FSKILL.md",[134,135,138,139],{"categoryNo":77,"categoryName":78,"taxonomyType":79,"taxonomyTypeDesc":80},{"categoryNo":136,"categoryName":137,"taxonomyType":79,"taxonomyTypeDesc":80},"01JBSEEDCAT000000000000023","Skill与智能体开发",{"categoryNo":82,"categoryName":83,"taxonomyType":84,"taxonomyTypeDesc":85},{"categoryNo":140,"categoryName":141,"taxonomyType":84,"taxonomyTypeDesc":85},"01JBSEEDCAT000000000000036","内容创作者",[143,144,145,146,147,148,149,150,151,25,152,153,154,155,156,157,158,159,160,161],"content","social content","social","Media","marketing","twitter","linkedin","instagram","social media","calendar","scheduling","tiktok","content calendar","content creation","facebook","viral","strategies","platform","creation",{"skillNo":163,"name":93,"nameZh":6,"description":164,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":165,"categories":166,"keywords":169,"publishedAt":34},"01M6DZ5NDBE4821RDH11V7FQTK","Optimize for search engine visibility and ranking. Use when asked to \"improve SEO\", \"optimize for search\", \"fix meta tags\", \"add structured data\", \"sitemap optimization\", or \"search engine optimization\".","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Fseo\u002FSKILL.md",[167,168],{"categoryNo":77,"categoryName":78,"taxonomyType":79,"taxonomyTypeDesc":80},{"categoryNo":82,"categoryName":83,"taxonomyType":84,"taxonomyTypeDesc":85},[93,170,33,171,172,173,174,175,30,176,27,26,25,23,177,178],"structured data","search","Optimization","data","Meta","Meta Tags","engine","structured","ranking",{"skillNo":180,"name":181,"nameZh":6,"description":182,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":183,"categories":184,"keywords":190,"publishedAt":34},"01M6DZ39W3BS39MBVGBDA38DV9","vercel-react-best-practices","React and Next.js performance optimization guidelines from Vercel Engineering. This skill should be used when writing, reviewing, or refactoring React\u002FNext.js code to ensure optimal performance patterns. Triggers on tasks involving React components, Next.js pages, data fetching, bundle optimization, or performance improvements.","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Freact-best-practices\u002FSKILL.md",[185,186,187],{"categoryNo":103,"categoryName":104,"taxonomyType":79,"taxonomyTypeDesc":80},{"categoryNo":136,"categoryName":137,"taxonomyType":79,"taxonomyTypeDesc":80},{"categoryNo":188,"categoryName":189,"taxonomyType":84,"taxonomyTypeDesc":85},"01JBSEEDCAT000000000000030","开发工程师",[116,191,91,192,193,194,5,115,195,196,197,198,172,173,199,200,201,202,203,204],"vercel react best practices","react best practices","vercel","writing","react components","guidelines","tasks","code","Next.js","refactoring","patterns","next","pages","triggers",{"skillNo":206,"name":207,"nameZh":6,"description":208,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":209,"categories":210,"keywords":216,"publishedAt":34},"01M6DZ2C3HPF1JX3TD508SXNDR","supabase-postgres-best-practices","Postgres performance optimization and best practices from Supabase. Use this skill when writing, reviewing, or optimizing Postgres queries, schema designs, or database configurations.","https:\u002F\u002Fgithub.com\u002Fkennyolofsson23-netizen\u002Fclaude-code-config\u002Fblob\u002Fmain\u002Fskills\u002Fpostgres-best-practices\u002FSKILL.md",[211,214,215],{"categoryNo":212,"categoryName":213,"taxonomyType":79,"taxonomyTypeDesc":80},"01JBSEEDCAT000000000000010","后端与接口",{"categoryNo":136,"categoryName":137,"taxonomyType":79,"taxonomyTypeDesc":80},{"categoryNo":188,"categoryName":189,"taxonomyType":84,"taxonomyTypeDesc":85},[91,217,218,219,220,194,5,198,221,222,172,223,224,225,25,226,227,228,229,230],"supabase postgres best practices","supabase","postgres best practices","postgres","database","examples","analysis","correct","Rules","schema","query","across","critical","impact"]