본문으로 건너뛰기
Skillpedia
웹사이트 및 UI (프런트엔드)7.8k · #13041

create-full-stack-panel-feature-with-server-wiring

하는 일

이 스킬은 백엔드, 프런트엔드, 서버 연결이 모두 필요한 새 대시보드 패널을 추가하는 과정을 AI 에이전트에게 안내합니다. 새 패널이 기존 코드와 맞기를 원하는 개발자를 위한 스킬입니다.

사용하는 경우

  • ✓관리자 대시보드나 대시보드에 새 패널 유형을 추가할 때.
  • ✓기능이 서버 라우트, 서비스, UI 컴포넌트에 걸쳐 있을 때.
  • ✓서버가 Express 라우팅 대신 수동 요청 분배를 사용할 때.

스킬 링크

https://github.com/HKUDS/AgentPilot/blob/main/openspace/legacy/v1/showcase/skills/create-full-stack-panel-feature-with-server-wiring/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/HKUDS/AgentPilot/blob/main/openspace/legacy/v1/showcase/skills/create-full-stack-panel-feature-with-server-wiring/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“제 대시보드에 새 지표 패널을 추가해 주세요. 서버 라우트와 서비스도 함께 만들고, 작동하도록 라우트를 서버에 연결해 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

에이전트는 기존 라우트, 서비스, 컴포넌트, 서버 진입점의 예시를 찾습니다. 그 파일을 읽어 관례를 파악한 뒤 새 파일을 만들고, 새 라우트 핸들러를 서버의 분배 테이블에 추가합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Create Full-Stack Panel Feature (with Server Wiring)

This skill guides you through creating a complete, pattern-consistent panel feature across all application layers: backend API routes, service logic, frontend components, registration, styling — and crucially, wiring the new route handler into the server's dispatch table, whether that uses Express or a manual http.createServer pattern.

When to Use

  • Adding a new panel type to a dashboard or admin interface
  • Creating a feature that spans multiple architectural layers
  • Ensuring consistency with existing codebase patterns across the stack
  • Projects that use a manual http.createServer dispatch loop instead of Express router mounting

Workflow Steps

1. Identify Pattern Files

Locate existing examples for each layer you need to implement:

# Find existing server routes
find . -name "*route*.js" -o -name "*routes*.js" -o -name "*route*.ts" -o -name "*routes*.ts" | grep -E "(panel|dashboard|server)"

# Find service files
find . -name "*service*.js" -o -name "*service*.ts" | grep -E "(panel|dashboard|server)"

# Find UI components
find . -name "*.jsx" -o -name "*.tsx" -o -name "*.ts" | grep -i panel

# Find the server entry point (critical for wiring step)
find . -name "index.ts" -o -name "index.js" -o -name "server.ts" -o -name "server.js" | grep -v node_modules | head -10

# Find registration/config files
find . -name "*config*.js" -o -name "*registry*.js" -o -name "*config*.ts" -o -name "*registry*.ts"

# Find styling files
find . -name "*.css" -o -name "*.scss" | grep -i panel

2. Read and Analyze Patterns

Read 1-2 representative examples from each layer to understand:

  • Naming conventions (e.g., MetricsPanel, metrics-service.ts)
  • Code structure and organization
  • Import/export patterns
  • Registration mechanisms
  • API endpoint patterns
  • Error handling approaches
  • Styling conventions

Also read the server entry point (server/index.ts, src/server.ts, etc.) to determine which dispatch pattern is used:

# Read the server entry point to identify routing mechanism
cat server/index.ts   # or server/index.js, src/server.ts, etc.

Example analysis checklist:

Server Route Pattern:
- ✓ Endpoint naming: /api/panels/{type}
- ✓ Authentication middleware
- ✓ Response format: { success, data, error }

Service Pattern:
- ✓ Export structure: class vs functions
- ✓ Data transformation logic
- ✓ Error propagation

Component Pattern:
- ✓ Props interface
- ✓ State management (hooks/class)
- ✓ Data fetching approach
- ✓ Loading/error states

Registration Pattern:
- ✓ Registry file location
- ✓ Registration format (array/object)
- ✓ Required metadata fields

Server Dispatch Pattern:
- ✓ Express app.use() / router.use()  → Express routing
- ✓ switch/case on url/pathname       → Manual dispatch table
- ✓ if/else if chain on url           → Manual dispatch chain
- ✓ handler map object { '/path': fn }→ Handler map pattern

3. Plan Your Feature Files

Based on patterns, list the files you need to create and the existing files you need to update:

Typical full-stack panel structure:

  1. Server route handler (e.g., server/routes/system-health-route.ts)
  2. Service layer (e.g., server/services/system-health-service.ts)
  3. UI component (e.g., client/panels/SystemHealthPanel.ts)
  4. Panel registration (e.g., update client/config/panel-registry.ts)
  5. Styling (e.g., client/styles/system-health-panel.css)
  6. Type definitions (if TypeScript, e.g., types/system-health.ts)
  7. ⚠️ Server wiring (update server/index.ts to import and dispatch to the new handler)

3b. Detect Project Framework

Before selecting templates in Step 4, determine the frontend framework in use:

# Check for React
grep -s "react" package.json | head -5

# Check for TypeScript without React (vanilla TS)
ls client/components/*.ts 2>/dev/null | head -3
ls client/panels/*.ts 2>/dev/null | head -3

# Check for a Panel base class (common in vanilla TS dashboards)
grep -r "class.*Panel" client/ --include="*.ts" -l | head -3
grep -r "extends Panel" client/ --include="*.ts" -l | head -3

Decision rule:

  • If react or react-dom is present in package.json → use the React/JSX template (Step 4C-React).
  • If components are .ts files extending a Panel base class → use the Vanilla TS template (Step 4C-Vanilla).
  • When in doubt, read one or two existing component files to conf
자주 묻는 질문

서버 진입점을 먼저 찾는 이유는 무엇인가요?

연결 단계는 서버가 요청을 분배하는 방식에 달려 있어서, 그것을 먼저 찾아야 한다고 스킬은 설명합니다.

Express에서도 작동하나요?

네, 스킬은 Express 미들웨어와 수동 http.createServer의 switch 또는 case 방식을 모두 다룹니다.

기존 스타일과 맞출 수 있나요?

네, 스킬은 에이전트가 기존 예시를 읽어 새 코드가 같은 패턴을 따르도록 합니다.

상세 정보

작성자의 원본 설명

Multi-layer workflow for creating complete panel features by analyzing existing patterns and generating coordinated server routes, services, UI components, registration, styling files, AND explicitly wiring new handlers into the server's dispatch table (supports both Express middleware and manual http.createServer switch/case patterns).

repo: HKUDS/AgentPilot

인기도

GitHub 스타
7.8k
순위
#13041
라이선스
MIT
업데이트
2026. 11. 1.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬