vercel-react-best-practices

Identify performance bottlenecks in React/Next.js code and propose optimizations.

1|2|Updated Mar 17, 2026
One-click install
npx skills add https://github.com/xrplevm/cosmos-explorer --skill vercel-react-best-practices-xrplevm
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vercel-react-best-practices
Source: https://github.com/xrplevm/cosmos-explorer/tree/main/.agents/skills/vercel-react-best-practices
Command: npx skills add https://github.com/xrplevm/cosmos-explorer --skill vercel-react-best-practices-xrplevm

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

React/Next.js performance issues across large apps, requiring structured best practices to optimize rendering, bundle size, data fetching, and UX.

Core Features & Use Cases

  • Guidelines for code-splitting, server components, caching, and safe patterns.
  • Use cases: writing/reviewing/refactoring React/Next.js code; optimizing data fetching, bundle, and rendering.

Quick Start

Review code for waterfalls, lazy-load heavy modules, avoid barrel imports, and apply the top-priority patterns to start improving performance immediately.

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 identify React performance bottlenecks in a large Next.js application?

Identify React performance bottlenecks by reviewing component trees for data fetching waterfalls and rendering inefficiencies, then apply structured best practices to optimize server components and bundle size.

What is the best way to optimize bundle size when using Next.js server components?

The best way to optimize bundle size is by code-splitting heavy modules, avoiding barrel imports, and applying safe patterns specifically designed for Next.js server components to reduce unnecessary client-side JavaScript.

How does code-splitting work for React component trees to improve rendering performance?

Code-splitting improves React rendering performance by lazy-loading heavy modules across component trees, which prevents large bundles from blocking initial page renders and reduces waterfall data fetching issues.

Can I use these React performance optimizations on existing real-world projects?

Yes, you can apply these React performance optimizations to real-world projects by writing, reviewing, and refactoring existing code to enforce safe patterns and adhere to established guardrails without risky changes.

Why should I avoid barrel imports when optimizing Next.js data fetching and bundle strategies?

Avoid barrel imports during Next.js bundle optimization because they often pull unintended dependencies into the build, increasing bundle size and negating code-splitting benefits for server components and data fetching.

When should I not use lazy-loading for React server components?

Avoid lazy-loading when optimizing React server components if it introduces data fetching waterfalls or breaks established guardrails, as safe patterns must be enforced to prevent risky rendering behaviors.