analyze_jsx_props
Scan directories and files to analyze React component props, filter by component name or prop, and retrieve TypeScript type information.
Instructions
Analyze JSX/React component prop usage across files and directories.
Use this tool when you need to:
Understand what props a component accepts
Find all components in a codebase and their props
Analyze prop usage patterns in a project
Get TypeScript interface information for components
EXAMPLES:
Analyze all components in current directory: { "includeTypes": true }
Analyze all components in src/components: { "path": "src/components", "includeTypes": true }
Find all props for Button component in current directory: { "componentName": "Button", "includeTypes": true }
Find all usages of onClick prop in current directory: { "propName": "onClick", "includeTypes": false }
Analyze specific file with type info: { "path": "src/App.tsx", "includeTypes": true }
Returns:
Component names and their props
Prop types (when includeTypes is true)
File locations where components are defined
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "analyze_jsx_props"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Absolute or relative path to file or directory to analyze (e.g., "src/components" or "src/App.tsx", defaults to current directory) | . |
| componentName | No | Filter: analyze only this specific component name (e.g., "Button") | |
| propName | No | Filter: search only for this specific prop name (e.g., "onClick") | |
| includeTypes | No | Include TypeScript type information in results |