Synthèse automatique
Améliore les performances des applications web en optimisant les Core Web Vitals, le rendu React, le lazy loading, les images, le profiling backend et l'inférence LLM.
Points forts
- Couverture complète des métriques modernes (LCP, INP, CLS) avec les seuils 2026
- Stratégies concrètes pour React 19+ (compilateur, mémoïsation, virtualisation)
- Optimisation des images et du chargement différé (AVIF, code splitting)
- Profiling backend et optimisation de l'inférence LLM (vLLM, quantification)
Limites
- Nécessite une connaissance préalable des concepts de performance web
- Certaines optimisations (ex: React Compiler) peuvent nécessiter des mises à jour de dépendances
- Ne couvre pas les tests de performance automatisés ni l'observabilité en production
Utilisez cette compétence lorsque vous devez améliorer le temps de chargement, la réactivité et le score Lighthouse de votre application, ou optimiser le rendu React et le backend.
Évitez de l'utiliser pour de simples correctifs de performance sans analyse préalable, ou si votre projet est encore en phase de prototypage rapide.
Analyse de sécurité
SûrThe skill is a documentation-only skill with no executable code, destructive commands, or data exfiltration. Allowed tools are limited to safe read-only operations. No risky patterns present.
Aucun point d'attention détecté
Comment cette analyse est faiteExemples
Analyze my landing page and suggest improvements for Largest Contentful Paint (LCP) using preloading, SSR, and fetchpriority.Identify unnecessary re-renders in my React component and apply memoization or the React Compiler.Optimize all images on the site by converting to AVIF/WebP, adding responsive sizes, and using lazy loading.name: performance license: MIT compatibility: "Claude Code 2.1.59+." description: Performance optimization patterns covering Core Web Vitals, React render optimization, lazy loading, image optimization, backend profiling, and LLM inference. Use when improving page speed, debugging slow renders, optimizing bundles, reducing image payload, profiling backend, or deploying LLMs efficiently. tags: [performance, core-web-vitals, lcp, inp, cls, react-compiler, virtualization, lazy-loading, code-splitting, image-optimization, avif, profiling, vllm, quantization, inference, caching, redis, prompt-caching, tanstack-query, prefetching, optimistic-updates] context: fork agent: frontend-ui-developer version: 2.0.0 author: OrchestKit user-invocable: false disable-model-invocation: true complexity: high metadata: category: document-asset-creation allowed-tools:
- Read
- Glob
- Grep
- WebFetch
- WebSearch
Performance
Comprehensive performance optimization patterns for frontend, backend, and LLM inference.
Quick Reference
| Category | Rules | Impact | When to Use | |----------|-------|--------|-------------| | Core Web Vitals | 3 | CRITICAL | LCP, INP, CLS optimization with 2026 thresholds | | Render Optimization | 3 | HIGH | React Compiler, memoization, virtualization | | Lazy Loading | 3 | HIGH | Code splitting, route splitting, preloading | | Image Optimization | 3 | HIGH | Next.js Image, AVIF/WebP, responsive images | | Profiling & Backend | 3 | MEDIUM | React DevTools, py-spy, bundle analysis | | LLM Inference | 3 | MEDIUM | vLLM, quantization, speculative decoding | | Caching | 2 | HIGH | Redis cache-aside, prompt caching, HTTP cache headers | | Query & Data Fetching | 2 | HIGH | TanStack Query prefetching, optimistic updates, rollback |
Total: 22 rules across 8 categories
Core Web Vitals
Google's Core Web Vitals with 2026 stricter thresholds.
| Rule | File | Key Pattern |
|------|------|-------------|
| LCP Optimization | rules/cwv-lcp.md | Preload hero, SSR, fetchpriority="high" |
| INP Optimization | rules/cwv-inp.md | scheduler.yield, useTransition, requestIdleCallback |
| CLS Prevention | rules/cwv-cls.md | Explicit dimensions, aspect-ratio, font-display |
2026 Thresholds
| Metric | Current Good | 2026 Good | |--------|--------------|-----------| | LCP | <= 2.5s | <= 2.0s | | INP | <= 200ms | <= 150ms | | CLS | <= 0.1 | <= 0.08 |
Render Optimization
React render performance patterns for React 19+.
| Rule | File | Key Pattern |
|------|------|-------------|
| React Compiler | rules/render-compiler.md | Auto-memoization, "Memo" badge verification |
| Manual Memoization | rules/render-memo.md | useMemo/useCallback escape hatches, state colocation |
| Virtualization | rules/render-virtual.md | TanStack Virtual for 100+ item lists |
Lazy Loading
Code splitting and lazy loading with React.lazy and Suspense.
| Rule | File | Key Pattern |
|------|------|-------------|
| React.lazy + Suspense | rules/loading-lazy.md | Component lazy loading, error boundaries |
| Route Splitting | rules/loading-splitting.md | React Router 7.x, Vite manual chunks |
| Preloading | rules/loading-preload.md | Prefetch on hover, modulepreload hints |
Image Optimization
Production image optimization for modern web applications.
| Rule | File | Key Pattern |
|------|------|-------------|
| Next.js Image | rules/images-nextjs.md | Image component, priority, blur placeholder |
| Format Selection | rules/images-formats.md | AVIF/WebP, quality 75-85, picture element |
| Responsive Images | rules/images-responsive.md | sizes prop, art direction, CDN loaders |
Profiling & Backend
Profiling tools and backend optimization patterns.
| Rule | File | Key Pattern |
|------|------|-------------|
| React Profiling | rules/profiling-react.md | DevTools Profiler, flamegraph, render counts |
| Backend Profiling | rules/profiling-backend.md | py-spy, cProfile, memory_profiler, flame graphs |
| Bundle Analysis | rules/profiling-bundle.md | vite-bundle-visualizer, tree shaking, performance budgets |
LLM Inference
High-performance LLM inference with vLLM, quantization, and speculative decoding.
| Rule | File | Key Pattern |
|------|------|-------------|
| vLLM Deployment | rules/inference-vllm.md | PagedAttention, continuous batching, tensor parallelism |
| Quantization | rules/inference-quantization.md | AWQ, GPTQ, FP8, INT8 method selection |
| Speculative Decoding | rules/inference-speculative.md | N-gram, draft model, 1.5-2.5x throughput |
Caching
Backend Redis caching and LLM prompt caching for cost savings and performance.
| Rule | File | Key Pattern |
|------|------|-------------|
| Redis & Backend | rules/caching-redis.md | Cache-aside, write-through, invalidation, stampede prevention |
| HTTP & Prompt | rules/caching-http.md | HTTP cache headers, LLM prompt caching, semantic caching |
Query & Data Fetching
TanStack Query v5 patterns for prefetching and optimistic updates.
| Rule | File | Key Pattern |
|------|------|-------------|
| Prefetching | rules/query-prefetching.md | Hover prefetch, route loaders, queryOptions, Suspense |
| Optimistic Updates | rules/query-optimistic.md | Optimistic mutations, rollback, cache invalidation |
Quick Start Example
// LCP: Priority hero image with SSR
import Image from 'next/image';
export default async function Page() {
const data = await fetchHeroData();
return (
<Image
src={data.heroImage}
alt="Hero"
priority
placeholder="blur"
sizes="100vw"
fill
/>
);
}
Key Decisions
| Decision | Recommendation | |----------|----------------| | Memoization | Let React Compiler handle it (2026 default) | | Lists 100+ items | Use TanStack Virtual | | Image format | AVIF with WebP fallback (30-50% smaller) | | LCP content | SSR/SSG, never client-side fetch | | Code splitting | Per-route for most apps, per-component for heavy widgets | | Prefetch strategy | On hover for nav links, viewport for content | | Quantization | AWQ for 4-bit, FP8 for H100/H200 | | Bundle budget | Hard fail in CI to prevent regression |
Common Mistakes
- Client-side fetching LCP content (delays render)
- Images without explicit dimensions (causes CLS)
- Lazy loading LCP images (delays largest paint)
- Heavy computation in event handlers (blocks INP)
- Layout-shifting animations (use transform instead)
- Lazy loading tiny components < 5KB (overhead > savings)
- Missing error boundaries on lazy components
- Using GPTQ without calibration data
- Not benchmarking actual workload patterns
- Only measuring in lab environment (need RUM)
Related Skills
ork:react-server-components-framework- Server-first renderingork:vite-advanced- Build optimizationcaching- Cache strategies for responsesork:monitoring-observability- Production monitoring and alertingork:database-patterns- Query and index optimizationork:llm-integration- Local inference with Ollama
Capability Details
lcp-optimization
Keywords: LCP, largest-contentful-paint, hero, preload, priority, SSR Solves:
- Optimize hero image loading
- Server-render critical content
- Preload and prioritize LCP resources
inp-optimization
Keywords: INP, interaction, responsiveness, long-task, transition, yield Solves:
- Break up long tasks with scheduler.yield
- Defer non-urgent updates with useTransition
- Optimize event handler performance
cls-prevention
Keywords: CLS, layout-shift, dimensions, aspect-ratio, font-display Solves:
- Reserve space for dynamic content
- Prevent font flash and image pop-in
- Use transform for animations
react-compiler
Keywords: react-compiler, auto-memo, memoization, React 19 Solves:
- Enable automatic memoization
- Identify when manual memoization needed
- Verify compiler is working
virtualization
Keywords: virtual, TanStack, large-list, scroll, overscan Solves:
- Render 100+ item lists efficiently
- Dynamic height virtualization
- Window scrolling patterns
lazy-loading
Keywords: React.lazy, Suspense, code-splitting, dynamic-import Solves:
- Route-based code splitting
- Component lazy loading with error boundaries
- Prefetch on hover and viewport
image-optimization
Keywords: next/image, AVIF, WebP, responsive, blur-placeholder Solves:
- Next.js Image component patterns
- Format selection and quality settings
- Responsive sizing and CDN configuration
profiling
Keywords: profiler, flame-graph, py-spy, DevTools, bundle-analyzer Solves:
- Profile React renders and backend code
- Generate and interpret flame graphs
- Analyze and optimize bundle size
llm-inference
Keywords: vllm, quantization, speculative-decoding, inference, throughput Solves:
- Deploy LLMs with vLLM for production
- Choose quantization method for hardware
- Accelerate generation with speculative decoding
References
- RUM Setup - Real User Monitoring
- React Compiler Migration - Compiler adoption
- TanStack Virtual - Virtualization patterns
- vLLM Deployment - Production vLLM config
- Quantization Guide - Method comparison
- CDN Setup - Image CDN configuration
Du fichier au premier essai
Le téléchargement contient exactement le contenu affiché sur cette fiche. Cette copie peut différer de la dernière version du dépôt source.
Consulter la source et ses fichiers annexesCe téléchargement contient uniquement SKILL.md. Les scripts, références, modèles et dépendances éventuels ne sont pas inclus. Récupérez les fichiers nécessaires depuis la source en conservant leur arborescence avant de poursuivre.
1. Télécharger le fichier
Télécharger SKILL.mdDepuis la racine d’un projet de test, enregistrez le fichier sous .skill-downloads/performance-optimization-mmbizk28/SKILL.md, ou utilisez la commande suivante. Ce dossier sert à examiner la skill avant son installation.
Commande pour macOS/Linux ou WSL : un shell POSIX et curl sont nécessaires. Sous Windows sans WSL, utilisez le bouton de téléchargement et créez le dossier manuellement.
mkdir -p '.skill-downloads/performance-optimization-mmbizk28' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/performance-optimization-mmbizk28/download' --output '.skill-downloads/performance-optimization-mmbizk28/SKILL.md.part' && mv '.skill-downloads/performance-optimization-mmbizk28/SKILL.md.part' '.skill-downloads/performance-optimization-mmbizk28/SKILL.md'2. Vérifier les prérequis
Lisez SKILL.md avant de l’utiliser. Si le fichier cite des scripts ou services externes, examinez-les et préparez les accès nécessaires dans votre environnement de test.
Environnement déclaré par l’auteur : Claude Code 2.1.59+.
Extrait original : Quick Reference
| Category | Rules | Impact | When to Use |
|---|---|---|---|
| Core Web Vitals | 3 | CRITICAL | LCP, INP, CLS optimization with 2026 thresholds |
| Render Optimization | 3 | HIGH | React Compiler, memoization, virtualization |
| Lazy Loading | 3 | HIGH | Code splitting, route splitting, preloading |
| Image Optimization | 3 | HIGH | Next.js Image, AVIF/WebP, responsive images |
| Profiling & Backend | 3 | MEDIUM | React DevTools, py-spy, bundle analysis |
| LLM Inference | 3 | MEDIUM | vLLM, quantization, speculative decoding |
| Caching | 2 | HIGH | Redis cache-aside, prompt caching, HTTP cache headers |
| Query & Data Fetching | 2 | HIGH | TanStack Query prefetching, optimistic updates, rollback |
Total: 22 rules across 8 categories
Les plateformes de la fiche sont des indications du catalogue. Les chemins ci-dessous suivent la documentation des outils ; ils ne prouvent pas que cette skill y a été exécutée. Aucune version minimale de ces outils n’est attestée pour cette fiche.
3. Charger la skill
Après vérification, copiez le dossier complet dans le projet avec l’une des commandes ci-dessous, puis ouvrez une nouvelle session de l’outil. La commande s’arrête si un dossier du même nom existe déjà : comparez les fichiers avant de le remplacer.
Claude Code
test -f '.skill-downloads/performance-optimization-mmbizk28/SKILL.md' && test -s '.skill-downloads/performance-optimization-mmbizk28/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/performance' && cp -R '.skill-downloads/performance-optimization-mmbizk28' '.claude/skills/performance'OpenSkills
OpenSkills doit déjà être installé. La procédure locale install/read est contrôlée avec OpenSkills 1.5.0, qui exige Node.js ≥ 20.6.0. Aucun slug du catalogue n’est résolu automatiquement.
Installation officielle d’OpenSkillsopenskills install './.skill-downloads/performance-optimization-mmbizk28'openskills read 'performance-optimization-mmbizk28'La lecture doit afficher le contenu du fichier installé et son dossier de base. Elle ne lance ni la skill ni ses dépendances.
Pour un agent qui lit AGENTS.md, synchronisez ensuite l’index. Cette commande modifie AGENTS.md : relisez le diff avant de l’utiliser.
openskills syncMode manuel ou autre outil : joignez SKILL.md à une conversation, ou ouvrez-le dans un agent capable de lire les fichiers. Ajoutez les ressources annexes nécessaires. Il n’existe pas de dossier universel reconnu par tous les outils.
4. Faire un premier essai
Utilisez une entrée courte et fictive : un endpoint d’API, un petit document ou un brief d’interface. Dans une nouvelle conversation, joignez le fichier ou donnez son chemin à l’agent, puis adaptez cette demande :
Lis .skill-downloads/performance-optimization-mmbizk28/SKILL.md et applique ses instructions à cet exemple : [décrire une entrée de test]. Indique les fichiers, dépendances ou accès qui manquent. Produis le résultat demandé par la skill sans inventer de données ni exécuter de script non examiné.Résultat attendu : une sortie correspondant aux instructions de la skill, ou une liste précise des prérequis manquants. Une simple confirmation de lecture ne valide pas le premier usage. Si une ressource externe est indisponible, ce parcours reste à tester.
Bonnes pratiques React Hook Form
Developpement
Maîtrisez React Hook Form : évitez les anti-patterns, gérez les abonnements, et traitez correctement reset, dirty state et entrées contrôlées.
Migration Emotion vers Mantine
Developpement
Migrer les styled-components Emotion vers des composants Mantine avec style props et modules CSS. Pour convertir .styled.tsx ou supprimer les imports @emotion.
Détecteur de dérive de périmètre
Developpement
Analyse les diffs git par rapport à une intention pour détecter la dérive de périmètre, fichiers non liés et PR trop larges, puis suggère de garder, diviser ou justifier.