Reuse Shared Props
USE shared prop types from @lib/ui/props WHEN defining component props TO avoid duplication
by vultisig★ 22 GitHub stars
Install Reuse Shared Props in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
About this skill
Reuse Shared Props
When defining component props, import and compose shared prop types from @lib/ui/props using & instead of defining inline equivalents.
Available Props
| Prop Type | Fields |
|---|---|
InputProps<T> |
value: T, onChange: (value: T) => void |
ValueProp<T> |
value: T |
OptionsProp<T> |
options: readonly T[] |
OnClickProp |
onClick: () => void |
OnFinishProp<T?, Mode?> |
onFinish: (value: T) => void (supports 'optional' mode) |
OnSuccessProp<T?, Mode?> |
onSuccess: (value: T) => void (supports 'optional' mode) |
OnBackProp |
onBack: () => void |
OnCloseProp |
onClose: () => void |
OnRemoveProp |
onRemove: () => void |
TitleProp |
title: ReactNode |
DescriptionProp |
description: ReactNode |
LabelProp |
label: ReactNode |
MessageProp |
message: ReactNode |
ChildrenProp |
children: ReactNode |
IconProp |
icon: ReactNode |
ActionProp |
action: ReactNode |
IsDisabledProp |
isDisabled?: boolean | string |
IsActiveProp |
isActive?: boolean |
StatusProp<T> |
status: T |
KindProp<T> |
kind: T |
UiProps |
style?: CSSProperties, className?: string |
AsProp<T> |
as?: T (polymorphic element type) |
RenderProp<T?> |
render: (value: T) => ReactNode |
SvgProps |
SVGProps<SVGSVGElement> (see svg-icon-pattern skill) |
onChange vs onValueChange
InputProps uses onChange, but TextInput uses onValueChange. Map accordingly:
<TextInput value={value} onValueChange={onChange} />
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
FAQ
What does the Reuse Shared Props skill do?
USE shared prop types from @lib/ui/props WHEN defining component props TO avoid duplication
How do I install the Reuse Shared Props skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the Reuse Shared Props skill run scripts?
No, this skill is instructions only (SKILL.md) with no executable scripts.
Related skills
frontend-design
AnthropicGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making…
webapp-testing
AnthropicToolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing…
brand-guidelines
AnthropicApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand…
web-artifacts-builder
AnthropicSuite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use…