What problem does it solve?
This Skill tackles slow load times, large bundle sizes, and inefficient rendering in React and Next.js applications by providing a structured set of performance‑focused guidelines.
Core Features & Use Cases
- Eliminating async waterfalls: Optimize data fetching with parallelism and early promise start.
- Bundle size reduction: Avoid barrel imports, apply dynamic imports, and defer non‑critical libraries.
- Server‑side efficiency: Authenticate server actions, use caching (React.cache and LRU), and minimize serialization.
- Client‑side data handling: Deduplicate event listeners, use passive scroll listeners, and manage localStorage wisely.
- Render & re‑render tuning: Apply memoization, transition APIs, and SVG/content‑visibility tricks.
- Real‑world scenario: When refactoring a Next.js page that suffers from long Time‑to‑Interactive, applying these rules yields faster first paint and lower CPU usage.
Quick Start
Use the react‑best‑practices skill to refactor a Next.js component for faster load time and reduced bundle size.