vercel-react-best-practices

Review React and Next.js code for performance and correctness issues.

Updated Jan 5, 2025
One-click install
npx skills add https://github.com/IdkwhatImD0ing/PortfolioV3 --skill vercel-react-best-practices-idkwhatimd0ing
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vercel-react-best-practices
Source: https://github.com/IdkwhatImD0ing/PortfolioV3/tree/main/.agents/skills/vercel-react-best-practices
Command: npx skills add https://github.com/IdkwhatImD0ing/PortfolioV3 --skill vercel-react-best-practices-idkwhatimd0ing

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps you write, review, and refactor React and Next.js code so it is faster, safer, and easier to maintain. It focuses on preventing performance regressions, rendering bugs, and inefficient data-fetching patterns before they reach production.

Core Features & Use Cases

  • Performance Guidance: Recommends patterns that reduce waterfalls, shrink bundles, and improve client and server rendering speed.
  • React and Next.js Best Practices: Covers React 19 features, Next.js 15 async request APIs, caching defaults, transitions, and server actions.
  • Refactoring Support: Helps convert inefficient code into cleaner implementations with better memoization, stable effects, and leaner prop passing.
  • Use Case: A team migrating an app to Next.js 15 can use this Skill to update async request handling, fix caching assumptions, and remove avoidable hydration issues.

Quick Start

Ask me to review your React or Next.js code for performance and correctness, and I will suggest best-practice refactors and implementation improvements.

Frequently Asked Questions about vercel-react-best-practices

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

FAQPage Schema
How do I fix React hydration errors and rendering bugs during a Next.js migration?

Fix React hydration errors by enforcing cache-aware server patterns and lean client props. This approach eliminates avoidable hydration mismatches during Next.js migrations by ensuring safe refactors grounded in production-grade guidance.

What is the best way to optimize React bundle size and prevent performance regressions?

Optimize React bundle size by applying lean client props, stable hooks, and parallel data fetches. This prevents performance regressions and shrinks client bundles by refactoring inefficient component design and data-fetching waterfalls.

How do I update async request handling and caching defaults for a Next.js 15 migration?

Update Next.js 15 async request handling by applying parallel fetches and cache-aware server patterns. This fixes outdated caching assumptions and aligns your codebase with Next.js 15 async request APIs to ensure safe server-side data flow.

Does this React refactoring approach support React 19 transitions and server actions?

Yes, this React refactoring approach supports React 19 features including transitions and server actions. It enforces stable hooks and memoization patterns to ensure safe component refactors across both React 19 and Next.js 15 migrations.

Why does my React app have data-fetching waterfalls and slow server rendering?

Data-fetching waterfalls and slow server rendering occur when parallel fetches are not enforced. Eliminate these inefficient data-fetching patterns by applying cache-aware server patterns and leaner prop passing for faster client and server rendering.

When should I not use memoization and stable hooks in my React components?

Avoid overusing memoization when it adds unnecessary overhead without resolving actual rendering bottlenecks. Focus on lean client props and stable effects instead, ensuring safe refactors that genuinely improve component performance and maintainability.