codegen_react_component
Generate accessible, production-ready React code from Figma component data, with optional TypeScript types.
Instructions
Generate a React component from Figma component data. Creates accessible, production-ready code with TypeScript support.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"componentData": "<componentData>",
"componentName": "<componentName>"
},
"name": "codegen_react_component"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| includeTypes | No | Include TypeScript types/interfaces | |
| componentData | Yes | Figma component data (from figma_get_component) | |
| componentName | Yes | Desired component name in PascalCase |