skills/prop-drill/SKILL.md
Trace React prop drilling
npx skillsauth add laststance/skills prop-drillInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
When running this skill in Codex, translate Claude Code-only primitives before acting: AskUserQuestion -> chat/request_user_input, TodoWrite -> update_plan, Task/TaskCreate/TeamCreate/SendMessage -> spawn_agent/send_input/wait_agent when available and allowed, and EnterPlanMode/ExitPlanMode -> a concise chat plan plus explicit approval.
Resolve Read/Write/Edit/Bash/WebSearch/WebFetch to Codex file/shell/web tools, and map ~/.claude/... paths to ~/.agents/... or ~/.codex/... unless the task explicitly targets Claude Code.
When running this skill in Cursor Agent, translate Claude Code-only primitives before acting: AskUserQuestion -> AskQuestion; TodoWrite -> Cursor TodoWrite or an equivalent checklist; Task/TaskCreate/TeamCreate/SendMessage/multi-agent flows -> Cursor Task (subagents), parallel Tasks, or run_in_background when allowed (TeamCreate/SendMessage may have no exact match); EnterPlanMode/ExitPlanMode -> Plan mode (SwitchMode / CreatePlan) plus explicit user approval.
Resolve Read/Write/Edit/StrReplace/Bash/web/search/MCP via Cursor Composer or Agent equivalents. MCP names written as mcp__server__tool typically map to call_mcp_tool with configured server identifiers. Map ~/.claude/... to ~/.cursor/skills/, .cursor/skills/, and .cursor/rules/ unless the task explicitly targets Claude Code.
Find where an unknown prop is originally defined and show the complete drilling path through the component tree. The origin code is displayed as a clickable code block in Cursor IDE so the user can jump to it instantly.
Parse the user's input to extract:
Examples of valid inputs:
orderDataorderData OrderTableorderData src/features/shared/order_status_tabs/order_table/OrderTable.tsxisOpen NewOrderModalLocate the type or type ... Props that declares this prop.
If Serena MCP is available:
search_for_pattern with propName in *.tsx / *.ts files filtered to type definitionsfind_symbol with include_body=True on the matched Props type& (intersection) or utility types, trace to the original typeOtherwise (standard tools):
Grep for the pattern propName\s*[\?:] in *.ts / *.tsx to find type declarationsRead the matched files to confirm the type definition contextIdentify where the prop's value is first created (not just passed through).
Look for patterns:
useState / useReducer — local stateuseQuery / useSWR / fetch — API datauseMemo / useCallback — computed valuesIf Serena MCP is available:
find_referencing_symbols on the Props type to list all components using itOtherwise:
Grep for <ComponentName or propName={ to find where the prop value is createdRead those files to distinguish origin from passthroughStarting from the origin component, trace downward through JSX:
propName={...} is passed to a child componentRecord for each step:
data={orderData})origin | passthrough | consumerIf Serena MCP is available:
find_referencing_symbols to efficiently discover child usageget_symbols_overview to quickly map component structureIf available:
Output in this exact order. The clickable code block is the most important part.
Show the prop's type definition and value origin as Cursor IDE clickable code blocks.
Use the startLine:endLine:filepath format (relative path from project root).
## Origin: `propName`
### Value created at:
```25:30:src/pages/orders/table.tsx
const orderData = useQuery({
queryKey: ["orders"],
queryFn: fetchOrders,
});
```
### Type defined at:
```12:16:src/types/order.ts
type OrderData = {
id: string;
status: OrderStatus;
};
```
Rules for code blocks:
startLine:endLine:filepath — NO language tag, NO other metadata## Drilling Path
| # | Component | File:Line | Prop Name | Role | Code |
|---|-----------|-----------|-----------|------|------|
| 1 | OrderPage | src/pages/orders/table.tsx:25 | orderData | origin | `const orderData = useQuery(...)` |
| 2 | OrderStatusTabs | src/features/.../OrderStatusTabs.tsx:40 | orderData | passthrough | `<OrderTable orderData={orderData} />` |
| 3 | OrderTable | src/features/.../OrderTable.tsx:15 | orderData | consumer | `orderData.map(...)` |
Role definitions:
## Component Flow
```mermaid
flowchart TD
OrderPage["OrderPage\n(origin)"] --> OrderStatusTabs["OrderStatusTabs\n(passthrough)"]
OrderStatusTabs --> OrderTable["OrderTable\n(consumer)"]
```
Mermaid rules:
\n for line breaks-->|"renamed: data"|Only show when drilling depth >= 3 layers.
## Suggestions
This prop passes through **N** layers. Consider:
- **Context API**: Extract `propName` into a Context provider at the `OriginComponent` level
- **Composition pattern**: Pass the consuming component as children instead of drilling the data
If exa MCP is available, search for real-world examples of the suggested pattern.
All MCP tools are optional. Use when available, fall back to standard tools.
| Need | Preferred (MCP) | Fallback (standard) |
|------|-----------------|---------------------|
| Find type definitions | Serena search_for_pattern + find_symbol | Grep + Read |
| Find references | Serena find_referencing_symbols | Grep for component usage |
| File structure | Serena get_symbols_overview | Glob + Read |
| React docs | context7 | Skip |
| Alternative patterns | exa | Skip |
tools
Inspect video frame-by-frame and capture-then-verify UI motion. Extract frames from any clip (handed to you, screen-recorded, or self-captured) with ffmpeg and read them as images; record an interaction (Playwright / computer-use / iOS simulator) and verify animations, transitions, and motion that static screenshots and getComputedStyle cannot reveal. Use when verifying animations/transitions/motion, analyzing a video or .webm/.mp4, extracting frames, checking how something "looks" in motion, or recording a UI flow to inspect.
testing
Cited research briefs
development
Daily coding habit prompts JP
development
React core deep-dive JP