Skip to main content
skill CX Codex

sort-components — Claude Code skill for organizing components

The sort-components Claude Code skill sorts UI components into folders by feature. It activates when adding a component or reorganizing apps/ui/components/.

AGPL-3.0 ★ 1,120 updated 2026-11-16

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add rerun-build/rerun --skill sort-components -a claude-code
Open on GitHub

What sort-components does

The skill groups files in apps/ui/components/ by what they do: chat pieces go in chat/, modal windows in dialogs/, and reusable primitives in ui/. New .tsx files belong in a subfolder, not at the directory root. If a component could fit by either its feature or its technical kind, the feature determines its location.

For an existing pile of root-level files, the workflow is to list them, assign destinations, move them with git mv, then switch imports to the @/components/<folder>/<File> alias. References between components and imports from apps/ui/app/ also need attention. Run cd apps/ui && npx tsc --noEmit to check import resolution; this requires the TypeScript npm package. Linting may still report existing code-quality issues.

What it helps with

  • place a new component in its feature folder
  • sort component files collected at the directory root
  • repair imports after moving components

Example prompts for the agent

  • Where should the new agent panel component go in apps/ui/components/?
  • Sort the files at the root of apps/ui/components/ and update their imports.

How to install sort-components

1Skills CLI (Vercel)

npx skills add rerun-build/rerun --skill sort-components -a claude-code

2Manually: put the files in place

~/.claude/skills/sort-components/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/sort-components/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about sort-components

How do I install sort-components in Claude Code?

Run npx skills add rerun-build/rerun --skill sort-components -a claude-code. The skill file is at ~/.claude/skills/sort-components/SKILL.md.

What does sort-components do?

It provides folder-placement rules for UI components and a process for moving existing files while repairing their imports.

How does sort-components check moved files?

Run cd apps/ui && npx tsc --noEmit to check whether imports resolve. The skill also mentions npm run lint and git status --short.

Similar skills

All skills for Frontend and UI →
components-build components.build components-build is a Claude Code skill for building, reviewing, and refactoring reusable React components with the components.build specification. It activates for work on component APIs, accessibility, styling, and TypeScript props. CX Codex +1 ★ 141repo stars building-components vercel building-components is a Claude Code skill for designing accessible UI components, composable APIs, design tokens, and documentation. CX Codex +1 15,400installs architecture-compound-components tech-leads-club The architecture-compound-components rule describes splitting complex UI components into pieces that share state through context. It fits components that have accumulated render props and conditional options. CX Codex +1 ★ 7,191repo stars animation-components Claude Design Skillstack animation-components — a Claude Code plugin that brings together animation and UI component libraries for React work. Use it when a screen needs motion effects or ready-made animated elements. ★ 1,428repo stars design-system-compound-components alexj11324 design-system-compound-components is a Claude Code rule that forbids raw string children in non-text components. It enforces compound structures like ButtonText and ButtonIcon across the design system. CX Codex +1 ★ 88repo stars figma-code-connect-components official openai figma-code-connect-components maps published Figma design components to codebase implementations using Figma Code Connect. It inspects component properties and pairs them with repository files. CX Codex +1 3,000installs

From the same set25

The whole set →
security-fix The security-fix Claude Code skill keeps vulnerability fixes in a private GitHub Security Advisory fork. It activates for security audit findings, private reports, or a pre-push rejection tied to vulnerability-related wording. CX Codex +1 ★ 1,120repo stars i18n-strings The i18n-strings Claude Code skill routes Rerun interface text through its translation setup. It activates for UI copy changes, date and number formatting, namespace extraction, or adding a language. CX Codex +1 ★ 1,120repo stars split-components The split-components Claude Code skill breaks up oversized component files into focused modules. It applies when a .tsx file grows crowded or before a new component is created. CX Codex +1 ★ 1,120repo stars confirm-destructive-actions The confirm-destructive-actions Claude Code skill sets confirmation rules for risky UI actions. It activates when adding a destructive button or writing a confirmation dialog. CX Codex +1 ★ 1,120repo stars loading-skeletons A Claude Code skill for building loading skeletons that match each component’s layout. It applies when adding a loading state or replacing a spinner in a content area. CX Codex +1 ★ 1,120repo stars investigate-bug investigate-bug — a skill for Claude Code that gathers evidence and traces a bug to its cause before a fix is written. It starts on bug reports, incidents, customer complaints, or requests to reproduce an issue. CX Codex +1 ★ 1,120repo stars form-field-labels form-field-labels — a Claude Code skill routes form titles through the shared Field component. It activates when adding or redesigning a field in apps/ui. CX Codex +1 ★ 1,120repo stars create-dialog The create-dialog Claude Code skill sets patterns for creating and redesigning app dialogs. Short forms use a basic frame; lists that open detail views use a panel with stepped navigation. CX Codex +1 ★ 1,120repo stars

Project sponsors

Companies that keep this analytics open