Antd Components Mcp

by zhixiaoqiang

244 stars
440 downloads
Not rated
GitHub Website

About

Provides Ant Design component documentation to large language models (LLMs), allowing them to explore and understand the components.

Details

Author
zhixiaoqiang
GitHub stars
244
Downloads
440
Categories
Developer Tools, Knowledge Base, Other

- Pre-processed Ant Design component data (version 6.5.0, 2026/6/29)
- List all available Ant Design components with descriptions
- View specific component documentation, props, and API definitions
- Access code examples and changelog for each component
- Extensive caching to reduce IO pressure
- Pre-configured prompts for efficient LLM interaction

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name Antd Components Mcp
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

Configure the server in your Claude Desktop configuration file (claude_desktop_config.json) using the npx command: npx @jzone-mcp/antd-components-mcp. Optionally, extract component documentation for other versions by cloning the Ant Design repository and running the extract command.

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "antd components mcp": {
            "antd-components-mcp": {
                "command": "npx",
                "args": [
                    "@jzone-mcp/antd-components-mcp",
                    "extract",
                    "[ant",
                    "design",
                    "repo",
                    "path]",
                    "#\u9ed8\u8ba4\u63d0\u53d6\u8def\u5f84\u4e3a",
                    "./ant-design"
                ]
            }
        }
    }
}

McpServers

{
    "antd-components-mcp": {
        "command": "npx",
        "args": [
            "@jzone-mcp/antd-components-mcp",
            "extract",
            "[ant",
            "design",
            "repo",
            "path]",
            "#\u9ed8\u8ba4\u63d0\u53d6\u8def\u5f84\u4e3a",
            "./ant-design"
        ]
    }
}

antd-components-mcp

<a href="https://glama.ai/mcp/servers/@zhixiaoqiang/antd-components-mcp">
antd-components-mcp MCP server
</a>

MseeP.ai Security Assessment Badge

npm version

<a href="./README.zh-CN.md">中文文档</a> |
<a href="#ant-design-components-mcp-service">English Documentation</a>

Ant Design Components MCP Service

A Model Context Protocol (MCP) server that provides Ant Design component documentation to large language models (LLMs) like Claude. This server allows LLMs to explore and understand Ant Design components through a set of dedicated tools.

Articles:

- 让 AI 更懂 Ant Design:MCP 协议在前端领域的落地实践

Features

- 🚀 Pre-processed data, ready to use (Pre-processed version: Ant Design V6.5.0 2026/6/29)
- 🔨 Can extract documentation for the latest/other versions
- 🔗 List all available Ant Design components
- 📃 Includes component name, description, available versions, and when to use the component
- 📃 View specific component documentation (filtered for context-friendly content)
- 📃 View component properties and API definitions
- 📃 View code examples for specific components
- 📖 View changelog for specific components
- 💪 Extensive caching to effectively reduce IO pressure
- ⚙️ Pre-configured prompt to reduce repetitive tool calls (optimized for context)
- 😺 Tested working with Claude client
- 😩 Currently not working with github copilot/Cline plugins

Version Mapping

This package follows a version mapping strategy where the package major version corresponds to Ant Design's major version:

- Ant Design 5.0 → Use package version 1.0.x
- Ant Design 6.0 → Use package version 2.0.x
- Ant Design 7.0 → Will correspond to package version 3.0.x (future)

Version Synchronization Strategy

When Ant Design releases a new major version, this package will release a corresponding new major version following the rule: Ant Design major version + 1 = Package major version.

For example:
- When Ant Design 7.0 is released, this package will release version 3.0.0
- The package version number is always one higher than the Ant Design major version to maintain clear version mapping

Each package version includes peerDependencies to help you select the correct version:
- Version 1.0.x requires antd ^5.0.0
- Version 2.0.x requires antd ^6.0.0
- Version 3.0.x will require antd ^7.0.0 (future)

Roadmap

- [x] Implement automatic data extraction when Ant Design components update
- [x] Add context awareness for tool calls (e.g. return "Please use previously obtained content")
- Implemented via the system-description prompt
- [ ] Add detailed MCP tools example documentation
- [ ] Consider hosting extracted data on CDN for real-time access
- Currently npx checks for and installs new versions automatically
- [ ] Support adjusting tool registration via parameters to improve context
- Some clients already support manual tool toggling (e.g. cline, github copilot)
- [ ] Consider compatibility with Ant Design 4.x or other UI libraries
- Such as Ant Design X series components

When to Extract Component Documentation Yourself?

1. You want to use the latest component documentation
2. You want to use documentation for other versions

Component Documentation

# Clone Ant Design repository
git clone https://github.com/ant-design/ant-design.git --depth 1 --branch master --single-branch --filter=blob:none

Run extraction command in current directory

npx @jzone-mcp/antd-components-mcp extract [ant design repo path] # Default path: ./ant-design

Component Changelog

Component changelog extraction depends on Ant Design's scripts/generate-component-changelog.ts script:

cd ant-design

pnpm install

Generate component changelog JSON

pnpm lint:changelog

Extract component information

npx @jzone-mcp/antd-components-mcp extract [ant design repo path]

This creates a data directory containing all extracted component documentation for the MCP server.

Claude Desktop Integration

To use this MCP server with Claude Desktop, edit the claude_desktop_config.json configuration file:

{
  "mcpServers": {
    "Ant Design Components": {
      "command": "npx",
      "args": ["@jzone-mcp/antd-components-mcp"]
    }
  }
}

Configuration file locations:

- macOS/Linux: ~/Library/Application Support/Claude/claude_desktop_config.json
- Windows: $env:AppData\Claude\claude_desktop_config.json

MCP Prompt

The server provides the following prompt for LLM interaction:

- system-description: Professional Ant Design components expert assistant that effectively reduces repetitive tool calls
- system-pages-generate: Professional frontend Ant Design page development assistant, effectively reducing repetitive tool calls - focused on page generation

> Note: For clients that don't support prompts, you can copy the following:

system-description

# Role Setting
You are a professional Ant Design component library expert assistant, focused on providing accurate and efficient component technical support.

Skills

Component Query

- Ability: Quickly retrieve and list all available components - Example: When user asks "what form components are available", list Form, Input, Select, etc.

Documentation Parsing

- Ability: Precisely obtain component props, API and usage instructions - Example: When user asks about "Table component's pagination configuration", return relevant props explanation

Component Code Example Query

- Ability: Accurately obtain component code examples - Example: When user requests "develop a Table component with loading capability using useState", query component examples then generate compliant example

Code Generation

- Ability: Provide complete runnable code examples - Requirements: - Query component documentation and examples before generation - Include necessary import statements and version information - Example: Generate a Select component example with search functionality

Version Tracking

- Ability: Query component update history and changes - Example: Answer "what changes were made to Modal component in v5.0.0"

Rules

1. Context first: Prioritize using existing conversation information, avoid duplicate queries 2. Exact matching: Component names and props must completely match official documentation 3. Minimal tool calls: Avoid duplicate tool calls for identical query parameters 4. Complete examples: All code examples must include full context and version information

system-pages-generate

```text

Role Setting:


You are a professional Ant Design component library expert assistant, focused on providing accurate and efficient component technical support. As a frontend business component development expert with decades of hands-on coding experience, you are proficient in coding principles such as the Single Responsibility Principle and Open-Closed Principle, and have deep understanding of design patterns.

Goals

- Clearly understand user's business component requirements - Before generating code, obtain component documentation and code examples through tools, then generate complete business component code that complies with code specifications based on user descriptions

Skills

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.