SKILL

vercel-composition-patterns

React composition patterns that scale. Use when refactoring components with boolean prop proliferation, building flexible component libraries, or designing reusable APIs. Triggers on tasks involving compound components, render props, context providers, or component architecture. Includes React 19 API changes.

Target: React / Next.js. Automatically collected · unverified.

Excerpt from the author’s documentation

Extracted from a fixed version of SKILL.md in its original language. This is the author’s documentation; installation, compatibility and runtime results have not been verified by this site.

Read the original English text

Topics in the source

  • React Composition Patterns
  • When to Apply
  • Rule Categories by Priority
  • Quick Reference
  • 1. Component Architecture (HIGH)
  • 2. State Management (MEDIUM)
  • 3. Implementation Patterns (MEDIUM)
  • 4. React 19 APIs (MEDIUM)

Composition patterns for building flexible, maintainable React components. Avoid boolean prop proliferation by using compound components, lifting state, and composing internals. These patterns make codebases easier for both humans and AI agents to work with as they scale. Reference these guidelines when: Refactoring components with many boolean props Building reusable component libraries Designing flexible component APIs Reviewing component architecture Working with compound components or context providers | Priority | Category | Impact | Prefix | | -------- | ----------------------- | ------ | --------------- | | 1 | Component Architecture | HIGH | architecture- | | 2 | State Management | MEDIUM | state- | | 3 | Implementation Patterns | MEDIUM | patterns- | | 4 | React 19 APIs | MEDIUM | react19- | architecture-avoid-boolean-props - Don't add boolean props to customize behavior; use composition architecture-compound-components - Structure complex components with shared context state-decouple-implementation - Provider is the only place that knows how state is managed state-context-interface - Define generic interface with state, actions, meta for dependency injection state-lift-st

This is an excerpt. Refer to the complete source and its current requirements.

Source repository
vercel-labs/agent-skills
Source file
skills/composition-patterns/SKILL.md
Fixed revision
1a2c79d4e6c4a2283dc2c614b6538cbe1ed5ca62
Read the complete original documentation ↗

Sources and evidence

This record was collected automatically. Its documentation, suitability and runtime behavior have not been manually verified.

Author: Vercel Agent Skills · original repository metadata. Documentation review: Not reviewed. Last source check: 2026-11-09T14:01:38.329Z.

Categories are inferred from names, descriptions and paths. They do not establish compatibility.

License and attribution

MIT. Third-party content and copyright remain with their authors. Refer to the original license and terms.

Original license ↗

Synchronization, copying and user-reported success do not mark a resource as runtime-tested.

Limitations and notes

  • Collecting metadata does not mean this site has installed, adapted, runtime-tested or security-reviewed the resource.