AR

azer/react-analyzer-mcp

Developer tools

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

58 stars 6 forks 品質 39 トレンド 13

ローカルで React コードの docs を分析・生成するための MCP サーバー

概要

Model Context プロトコルを使用して React コードのドキュメントを解析&生成します。 react-analyzerライブラリに基づく。 このツールは React コンポーネントファイル (JSX/TSX) を解析し、コンポーネントとそのプロップに関する情報を抽出します。 - : ソースコードから単一の React コンポーネントを分析します。 - : プロジェクトフォルダ内のすべての React コンポーネントのドキュメントを生成します。 : root フォルダ内のすべてのプロジェクトをリストします。 1。 Claudeデスクトップの設定でMCPサーバーを有効にします。 2。 Claude Shellを使用してMCPサーバーにClaudeを接続します。 3. 直接Claudeの会話でツールを使用する:

概要(AI 翻訳)

Model Context プロトコルを使用して React コードのドキュメントを解析&生成します。 react-analyzerライブラリに基づく。

それが何をするか

このツールは React コンポーネントファイル (JSX/TSX) を解析し、コンポーネントとそのプロップに関する情報を抽出します。

利用可能なツール

  • 分析反応: ソースコードから単一の React コンポーネントを分析
  • 分析プロジェクト: プロジェクトフォルダ内のすべての React コンポーネントのドキュメントを生成
  • リストプロジェクト: ルートフォルダ内のすべてのプロジェクトをリスト

インストール

Claudeで使用

1。 Claudeデスクトップの設定でMCPサーバーを有効にします。

2。 Claude Shellを使用してMCPサーバーにClaudeを接続します。

  1. 直接Claudeの会話でツールを使用する:

または:

例

##プロジェクトフォルダの分析:

入力:

出力:

ライセンス

ログイン

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。

README

react-analyzer-mcp

Analyze & generate docs for React code using the Model Context Protocol. Based on react-analyzer library.

What it does

This tool analyzes React component files (JSX/TSX) and extracts information about components and their props.

Available Tools

  • analyze-react: Analyzes a single React component from source code
  • analyze-project: Generates documentation for all React components in a project folder
  • list-projects: Lists all projects under the root folder

Installation

# Clone the repository
git clone https://github.com/azer/react-analyzer-mcp.git
cd react-analyzer-mcp

# Install dependencies
npm install

# Update PROJECT_ROOT in the index.ts file.
vim src/index.ts

# Build
npm run build

Using with Claude

  1. Enable MCP server in the Claude Desktop config:
{
    "react-analyzer-mcp": {
      "command": "node",
      "args": [
        "/Users/azer/code/sandbox/react-analyzer-mcp/build/index.js"
      ]
    }
}
  1. Connect Claude to your MCP server using the Claude Shell.

  2. Use the tools directly in Claude conversations:

Analyze my project's React components in the "ui" folder.

Or:

What React components do I have in my project?

Examples

Analyzing a project folder:

Input:

Can you analyze the components in my "foobar" folder?

Output:

# Components

## Button

### Props

| Prop | Type | Optional | Default |
|------|------|----------|---------|
| `variant` | `string` | ✓ | `primary` |
| `size` | `string` | ✓ | `md` |
| `onClick` | `function` | ✓ | |
...

License

MIT

GitHub で README 全文を見る

インストール

This server does not publish a one-line install command.

Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →