installskill

Skills / vercel-labs/agent-skills

vercel-composition-patterns

React composition patterns for components that have outgrown boolean props.

Pinned commit
5a37a6329fbaCommitted 2026-11-20
Files
1449 KB
License
MIT
Snapshot taken
2026-11-28
Description from the skill
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.

This is the text your agent reads to decide when to use the skill.

Install

Choose your agent. Pinned commands install exactly the commit this page describes.

Skill directory .claude/skills/Claude Code · Official docs

Does not read the shared .agents/skills directory. A skill must land in .claude/skills, or arrive inside a plugin.

GitHub CLIpinned

$ gh skill install vercel-labs/agent-skills skills/composition-patterns --agent claude-code --pin 5a37a6329fbad3666c3207392a6a7c0110e92efb

gh picks the directory for the agent, names the folder after the source directory (composition-patterns), and writes source metadata into the SKILL.md frontmatter, so the content hash below will not match. Check the github-tree-sha it records instead: it should read bf90d0a4b83ea054653350f9c67f6de235d3a368.

skills CLIpinned

$ npx skills add vercel-labs/agent-skills@5a37a6329fbad3666c3207392a6a7c0110e92efb --skill vercel-composition-patterns -a claude-code --copy

Downloads and runs the skills package from npm. --copy writes real files instead of symlinks. The CLI sends anonymous telemetry unless DISABLE_TELEMETRY=1 is set, and that setting also turns off its audit lookups.

Plain gitpinned

$ tmp=$(mktemp -d)
$ git clone --quiet https://github.com/vercel-labs/agent-skills.git "$tmp"
$ git -C "$tmp" checkout --quiet 5a37a6329fbad3666c3207392a6a7c0110e92efb
$ mkdir -p .claude/skills
$ cp -R "$tmp/skills/composition-patterns" .claude/skills/vercel-composition-patterns

No extra tooling. Files land byte for byte as published in .claude/skills/vercel-composition-patterns, so the content hash below can be checked directly.

Check what landed

Run this after installing. It prints one SHA-256 for the whole directory. If your installer reported a different directory, cd there instead.

$ cd .claude/skills/vercel-composition-patterns && find . -type f -print0 | LC_ALL=C sort -z | xargs -0 shasum -a 256 | shasum -a 256

Expectedd493cd1038581ca5fbb841f1dbc86274febc36c251fb416548201999b1bfbb1e

It matches only when the files are byte for byte as published. A difference means something changed: by the installer, by you, or upstream.

What is inside

Pattern matches in the files, each linked to its line. A match is a place to read, not a verdict, and no match is not proof of absence.

Docs · 12SKILL.md · 1Data · 1

Runs commandsNo match

Code that spawns other processes, or shell code blocks in the instructions.

Network accessNo match

Calls that fetch from or send to a remote host.

Installs packagesNo match

Commands that pull and run third-party packages at use time.

Reads env or credentialsNo match

References to environment variables, tokens, keys or credential files.

Privileged or destructiveNo match

sudo, recursive deletes, permission changes and similar commands.

Dynamic or encoded codeNo match

eval, exec, base64 decoding and remote-script piping, which hide what runs.

Outside hosts mentioned

Hostnames of every URL in the text files.

  • react.dev×9
  • example.com×1

Entries worth a second look

No symlinks, submodules, hidden files, archives, compiled files or unscanned files.

File manifest

Every file in the skill directory at the pinned commit.

Content hash
d493cd1038581ca5fbb841f1dbc86274febc36c251fb416548201999b1bfbb1e
Git tree SHA
bf90d0a4b83ea054653350f9c67f6de235d3a368
PathKindSizeSHA-256
AGENTS.mdDocs22 KB89e3ddd58fcf99a5…
README.mdDocs2.1 KB85915a43a6f0b4ef…
SKILL.mdSKILL.md2.8 KBe38e0eaa609316b1…
metadata.jsonData530 B49262ed5cb4186f3…
rules/_sections.mdDocs829 Ba174213b87e6911e…
rules/_template.mdDocs329 B587f7d16b0660eb6…
rules/architecture-avoid-boolean-props.mdDocs2.2 KB007555ebb020f4d5…
rules/architecture-compound-components.mdDocs2.5 KBf246af13dc269b52…
rules/patterns-children-over-render-props.mdDocs1.8 KB7c45a0d21b3c4126…
rules/patterns-explicit-variants.mdDocs2.3 KB8c19e596e6180754…
rules/react19-no-forwardref.mdDocs953 B881830adb7534c4b…
rules/state-context-interface.mdDocs4.9 KB09e73afbf9285fa4…
rules/state-decouple-implementation.mdDocs2.6 KB76a8c1eb29a70d89…
rules/state-lift-state.mdDocs3.1 KB74c54038a6c554c7…

Spec and portability

Checked against the Agent Skills specification.

Frontmatter
Parses as YAML
Name matches directory
Novercel-composition-patterns ≠ composition-patterns. Installed as vercel-composition-patterns.
Name uses lowercase letters, digits and hyphens
Yes
Description length
310limit 1,024 characters
SKILL.md body
77 linesthe spec suggests under 500 lines
Fields outside the spec
None
License field
MIT
License file
None declared
Repository license
None declared

Change history

No changes recorded since the first snapshot on 2026-11-28.