Skip to main content
Glama
Shadcn UI MCP Server

Shadcn UI MCP Server

by heilgar

Shadcn UI MCP-сервер

Мощный и гибкий сервер MCP (Model Control Protocol), разработанный для улучшения опыта разработки с компонентами пользовательского интерфейса Shadcn. Этот сервер обеспечивает надежную основу для создания и управления компонентами пользовательского интерфейса с помощью передовых инструментов и функциональности.

Функции

Инструменты

Сервер MCP предоставляет набор инструментов, которые можно использовать через протокол управления моделью:

  • list-components : Получить список доступных компонентов shadcn/ui

  • get-component-docs : Получить документацию для определенного компонента

  • install-component : Установка компонента shadcn/ui

  • list-blocks : Получить список доступных блоков shadcn/ui

  • get-block-docs : Получить документацию для определенного блока

  • install-blocks : Установка блока shadcn/ui

Функциональность

  • Управление компонентами

    • Список доступных компонентов shadcn/ui

    • Получите подробную документацию по конкретным компонентам

    • Установка компонентов с поддержкой нескольких менеджеров пакетов (npm, pnpm, yarn, bun)

  • Управление блоками

    • Список доступных блоков shadcn/ui

    • Получить документацию и код для определенных блоков

    • Установка блоков с поддержкой нескольких менеджеров пакетов

  • Поддержка менеджера пакетов

    • Гибкая поддержка среды выполнения для npm, pnpm, yarn и bun

    • Автоматическое определение предпочитаемого пользователем менеджера пакетов

Related MCP server: aceternityui-mcp

Установка

Предпосылки

  • Node.js (v18 или выше)

  • менеджер пакетов npm или yarn

Конфигурация рабочего стола Клода

Для использования с Claude Desktop добавьте конфигурацию сервера:

В MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json В Windows: %APPDATA%/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "shadcn-ui-server": {
      "command": "npx",
      "args": ["@heilgar/shadcn-ui-mcp-server"]
    }
  }
}

Конфигурация виндсерфинга

Добавьте это в ваш ./codeium/windsurf/model_config.json :

{
  "mcpServers": {
    "shadcn-ui-server": {
      "command": "npx",
      "args": ["@heilgar/shadcn-ui-mcp-server"]
    }
  }
}

Конфигурация курсора

Добавьте это в ваш .cursor/mcp.json :

{
  "mcpServers": {
    "shadcn-ui-server": {
      "command": "npx",
      "args": ["@heilgar/shadcn-ui-mcp-server"]
    }
  }
}

Разработка и отладка

Местное развитие

  1. Установить зависимости:

npm install
  1. Сборка сервера:

npm run build

Отладка

Поскольку серверы MCP взаимодействуют через stdio, отладка может быть сложной. Мы рекомендуем использовать MCP Inspector для отладки:

npm run inspector

Инспектор предоставит URL-адрес для доступа к инструментам отладки в вашем браузере, что позволит вам:

  • Мониторинг связи MCP

  • Проверка вызовов и ответов инструментов

  • Отладка поведения сервера

  • Просмотр журналов в реальном времени

Связанные проекты и зависимости

Этот проект создан с использованием следующих инструментов и библиотек:

  • Model Context Protocol TypeScript SDK — официальный TypeScript SDK для серверов и клиентов MCP

  • MCP Inspector — инструмент отладки для серверов MCP

  • Cheerio — быстрая, гибкая и экономичная реализация ядра jQuery, разработанная специально для сервера

Лицензия

Лицензия MIT — можете свободно использовать этот проект в своих целях.

Внося вклад

Вклады приветствуются! Пожалуйста, не стесняйтесь отправлять запрос на включение.

Available Tools

6 tools
get-block-docsD

Inputs: block (required).

get-component-docsD

Inputs: component (required).

install-blocksD

Inputs: block (required), runtime.

install-componentD

Inputs: component (required), runtime.

list-blocksD

Inputs: no named parameters.

list-componentsD

Inputs: no named parameters.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.1/5.0

    Scored across 6 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose with no overlap: get-block-docs and get-component-docs retrieve documentation, install-blocks and install-component handle installation, and list-blocks and list-components provide listings. The block/component distinction and action types (get, install, list) create unambiguous boundaries.

    Naming Consistency5/5

    All tools follow a perfect verb-noun pattern with consistent kebab-case formatting: get-block-docs, get-component-docs, install-blocks, install-component, list-blocks, list-components. The naming is completely predictable and follows the same structural convention throughout.

    Tool Count4/5

    Six tools is reasonable for a Shadcn UI server, covering documentation retrieval, installation, and listing for both blocks and components. While slightly minimal, it provides core functionality without being overwhelming. A few additional tools like update or search might enhance it but aren't essential.

    Completeness4/5

    The toolset covers the main workflows for Shadcn UI: discovering components/blocks (list), accessing documentation (get), and installation (install). Minor gaps exist, such as no update/uninstall tools or search functionality, but the core CRUD-like operations for this domain are well-represented.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers