vercel-react-best-practices

Applies Vercel performance optimization rules when writing or refactoring React and Next.js code.

Updated Apr 16, 2026
One-click install
npx skills add https://github.com/quangtuyennguyen/loan-application-workflow --skill vercel-react-best-practices-quangtuyennguyen
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: vercel-react-best-practices
Source: https://github.com/quangtuyennguyen/loan-application-workflow/tree/main/.claude/skills/vercel-react-best-practices
Command: npx skills add https://github.com/quangtuyennguyen/loan-application-workflow --skill vercel-react-best-practices-quangtuyennguyen

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? React and Next.js codebases often suffer from slow load times, unnecessary re-renders, and data-fetching waterfalls that are hard to spot during development. This Skill provides a structured, prioritized rule set from Vercel Engineering so AI-assisted code generation and review consistently follows proven performance patterns. ## Core Features & Use Cases - 70 Prioritized Rules Across 8 Categories: Covers eliminating waterfalls, bundle size optimization, server-side performance, client-side data fetching, re-render optimization, rendering performance, JavaScript performance, and advanced patterns, each tagged by impact level from CRITICAL to LOW. - Incorrect vs. Correct Code Examples: Every rule includes concrete before/after TypeScript and TSX examples with explanations, making it directly applicable during refactoring. - Use Case: When reviewing a Next.js page that fetches user, posts, and comments sequentially, apply the async-parallel rule to rewrite the fetches with Promise.all(), cutting three round trips down to one. ## Quick Start Review my Next.js page component using the vercel-react-best-practices skill and fix any data-fetching waterfalls or bundle size issues.

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 eliminate data fetching waterfalls in Next.js?▼

Execute independent async operations concurrently with Promise.all() instead of sequential awaits, and start promises early in API routes before awaiting them. For partial dependencies, use better-all or chain promises so each task starts at the earliest possible moment.

How to reduce bundle size in a React application?▼

Avoid barrel file imports by importing directly from source files or using Next.js optimizePackageImports, lazy-load heavy components with next/dynamic, and defer non-critical third-party libraries like analytics until after hydration.

Does this guide work with React Server Components?▼

Yes, it includes server-side rules specific to RSC such as minimizing serialization at RSC boundaries, per-request deduplication with React.cache(), avoiding shared module state for request data, and authenticating Server Actions like API routes.

When should I not use Suspense boundaries for data fetching?▼

Avoid Suspense when data is critical for layout decisions, when content is SEO-critical above the fold, when queries are small and fast, or when you want to prevent layout shift between loading and loaded states.

Why do barrel file imports slow down React builds?▼

Barrel files re-export thousands of modules, forcing 200-800ms import costs on every cold start since bundlers cannot tree-shake external libraries. Libraries like lucide-react and @mui/material can load thousands of unused modules from a single import.