Skip to main content
Glama
favurr

shadcn-mcp-server

by favurr
README.md
# Shadcn MCP Server

A containerized Model Context Protocol (MCP) server that enables AI agents to dynamically install shadcn UI components into a mounted project workspace.

## Features

- **Standardized MCP Interface**: Exposes an `add_shadcn_component` tool to add shadcn components.
- **Dockerized Execution**: Run within a clean Docker environment, shielding host dependencies.
- **Seamless Volume Mounting**: Configured to run `npx shadcn@latest add` directly inside the mounted host codebase.
- **Automated Registry Publishing**: Automatically tags and pushes Docker images to GitHub Container Registry (GHCR) via GitHub Actions.

## Getting Started

### Usage in Docker MCP Toolkit

If your server is published to GitHub Container Registry, users can add it to their local IDE workspace with these steps:

1. **Create a local profile**:
   ```bash
   docker mcp profile create --name my-project
   ```

2. **Add the MCP server**:
   ```bash
   docker mcp profile server add my-project --server docker://ghcr.io/your-github-username/shadcn-mcp:latest
   ```

3. **Configure the workspace mount directory**:
   ```bash
   docker mcp profile config my-project --set shadcn-mcp.volumes=".:/workspace"
   ```

4. **Connect the profile to your IDE (VS Code)**:
   ```bash
   docker mcp client connect vscode --profile my-project
   ```

## Local Development

1. **Install dependencies**:
   ```bash
   npm install
   ```

2. **Build TypeScript**:
   ```bash
   npm run build
   ```

3. **Start the server**:
   ```bash
   npm start
   ```

TDQS

B3.2/5.0

Scored across 1 tool

Disambiguation5/5

Only one tool exists, so there is no risk of confusion between tools. Disambiguation is perfect.

Naming Consistency5/5

The single tool name follows a clear verb_noun pattern (add_shadcn_component) in snake_case, which is consistent and descriptive.

Tool Count3/5

With only one tool, the server feels thin for a component management server. While the core operation is covered, additional tools for listing or removing components might be expected.

Completeness2/5

The server only supports adding a component, missing obvious operations like listing available components or removing them. This limits the agent's ability to manage shadcn components effectively.

Maintenance

ActivityMaintained
ResponsivenessSyncing