[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6F27QS2ACBA1V3ZPAMY1XR9":3,"skill-same:01M6F27QS2ACBA1V3ZPAMY1XR9":67},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":36,"linkOnly":37,"markdownContent":38,"markdownBody":39,"frontMatter":40,"refName":44,"commitSha":45,"skillDirectory":46,"forksCount":47,"repositoryHtmlUrl":48,"repositoryHomepageUrl":49,"ownerHtmlUrl":50,"ownerBlogUrl":6,"ownerDescription":51,"updatedAt":52,"install":53,"resources":66},"01M6F27QS2ACBA1V3ZPAMY1XR9","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\".","ComeOnOliver\u002Fskillshub","ComeOnOliver","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F43215937?v=4","01M6E5JNFECJAAVFE0W7SMWWD2","Haoran Shu","01M6E5JNNDQS7AJZDYFQ8TPZCK",66,"GPL-3.0","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Falessioarzenton\u002Fclaude-code-wp-toolkit\u002Fperformance\u002FSKILL.md",[],[5,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35],"fix","loading","optimize web","user experience","speed","time","optimize","up","use","user","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: GPL-3.0\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\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\n",{"name":5,"license":15,"metadata":41,"description":7},{"author":42,"version":43},"web-quality-skills","1.0","main","def8531e65114c0fca8fb8551c1871ee0eed705c","skills\u002Falessioarzenton\u002Fclaude-code-wp-toolkit\u002Fperformance",24,"https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub","https:\u002F\u002Fskillshub.wtf","https:\u002F\u002Fgithub.com\u002FComeOnOliver","AI & Blockchain Engineer\r\n","2026-06-24 22:07:19",{"source":8,"skillName":5,"commands":54,"prompt":64,"zipAvailable":65},[55,58,61],{"tool":56,"command":57},"npx","npx skills add ComeOnOliver\u002Fskillshub --skill performance",{"tool":59,"command":60},"bunx","bunx skills add ComeOnOliver\u002Fskillshub --skill performance",{"tool":62,"command":63},"pnpm","pnpm dlx skills add ComeOnOliver\u002Fskillshub --skill performance","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Falessioarzenton\u002Fclaude-code-wp-toolkit\u002Fperformance\u002FSKILL.md",true,[],[68,83,93,102,108,115],{"skillNo":69,"name":70,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":71,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":79,"publishedAt":36},"01M6FKJN13GMG4KY57J3QD8GY5","model-hierarchy-skill","MIT","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzscole\u002Fmodel-hierarchy-skill\u002Fmodel-hierarchy-skill\u002FSKILL.md",[74],{"categoryNo":75,"categoryName":76,"taxonomyType":77,"taxonomyTypeDesc":78},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[80,81,82],"model","model hierarchy","model hierarchy skill",{"skillNo":84,"name":85,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":71,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":89,"publishedAt":36},"01M6FKJJJ6GCAMR4PPPRD12M5X","zoom-mcp","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-mcp\u002FSKILL.md",[88],{"categoryNo":75,"categoryName":76,"taxonomyType":77,"taxonomyTypeDesc":78},[90,91,92],"MCP","zoom","zoom mcp",{"skillNo":94,"name":95,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":71,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":98,"publishedAt":36},"01M6FKJE3KYT3KPEZMEEHYKA6K","zoom-apps-sdk","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-apps-sdk\u002FSKILL.md",[],[99,100,101,91],"sdk","zoom apps sdk","apps",{"skillNo":103,"name":104,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":71,"licenseFileUrl":6,"sourceHtmlUrl":105,"categories":106,"keywords":107,"publishedAt":36},"01M6FKJ9EDH9Q5VWDF8HAJRSP0","windows","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwindows\u002FSKILL.md",[],[104],{"skillNo":109,"name":110,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":71,"licenseFileUrl":6,"sourceHtmlUrl":111,"categories":112,"keywords":114,"publishedAt":36},"01M6FKJ666BEEFC3AE9GJ72Q93","whiteboard","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwhiteboard\u002FSKILL.md",[113],{"categoryNo":75,"categoryName":76,"taxonomyType":77,"taxonomyTypeDesc":78},[110],{"skillNo":116,"name":117,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":71,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":120,"publishedAt":36},"01M6FKJ21WFCDGTJQ2Q91T9DVW","websockets","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwebsockets\u002FSKILL.md",[],[117]]