frontend-performance

Diagnose and optimize frontend loading and runtime performance against Core Web Vitals.

1|Updated Aug 18, 2026
One-click install
npx skills add https://github.com/scsm-unrestrict/dsh-frontend-engineer-agent --skill frontend-performance-scsm-unrestrict
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: frontend-performance
Source: https://github.com/scsm-unrestrict/dsh-frontend-engineer-agent/tree/main/frontend-engineer/skills/frontend-performance
Command: npx skills add https://github.com/scsm-unrestrict/dsh-frontend-engineer-agent --skill frontend-performance-scsm-unrestrict

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Pages that load slowly, stutter during interaction, or score poorly on Core Web Vitals (LCP, INP, CLS) hurt user experience, yet optimization attempts without a measured baseline often waste effort or regress other metrics. This Skill enforces a measure-first workflow: establish a baseline, locate bottlenecks, optimize, then re-test with a before/after comparison. ## Core Features & Use Cases - Baseline Measurement: Capture LCP, INP, CLS, TTFB, FCP, and bundle sizes using Lighthouse, PageSpeed Insights, web-vitals, Chrome DevTools, and bundle analyzers (vite-bundle-visualizer, webpack-bundle-analyzer). - Loading Optimization: Route-level code splitting, tree-shaking, on-demand component library imports, gzip/brotli compression, CDN caching, critical CSS/JS inlining, font subsetting, and responsive AVIF/WebP images with lazy loading. - Runtime Optimization: Reduce reflows and repaints, use compositor-friendly transform/opacity animations, split long tasks, debounce high-frequency events, virtualize large lists, and eliminate unnecessary re-renders in React (memo, state placement) and Vue (computed, shallowRef). - Use Case: A user reports their React dashboard feels sluggish. The Skill guides measuring a Lighthouse baseline, identifying an oversized bundle and unmemoized re-renders, applying code splitting and memoization, then delivering a before/after metrics table. ## Quick Start Analyze my page's performance problems and give me an optimization plan with baseline metrics and a before/after comparison.

Frequently Asked Questions about frontend-performance

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I improve Core Web Vitals scores on my website?

Start by measuring a baseline with Lighthouse or PageSpeed Insights, then optimize in priority order: LCP first, then INP, then CLS. Common fixes include code splitting, image optimization with AVIF/WebP, font subsetting, and reducing long main-thread tasks.

How to reduce JavaScript bundle size in React or Vue apps?

Use route-level code splitting with lazy loading, verify tree-shaking works, import component libraries on demand (e.g., antd/es), and remove or upgrade oversized dependencies. Analyze the bundle with vite-bundle-visualizer or webpack-bundle-analyzer to find the largest contributors.

Why does my React app re-render too often?

Unnecessary re-renders usually come from poorly placed state, overly broad context, or missing memoization. Use React Profiler to locate the re-render source, then split components, apply memo, and narrow context scope.

What tools measure frontend performance metrics?

Lighthouse and PageSpeed Insights measure lab metrics like LCP and CLS, while the web-vitals library collects real-user metrics. Chrome DevTools Performance panel and framework profilers (React Profiler, Vue DevTools) diagnose runtime issues.

Should I always code-split every route and component?

Not necessarily. Code splitting reduces initial bundle size but increases request count, so the tradeoff depends on network conditions. Prioritize splitting non-first-screen routes and components, and document the reasoning behind each decision.