Help us improve
Share bugs, ideas, or general feedback.
npx claudepluginhub jhlee0409/claude-plugins --plugin fsdarchHow this command is triggered — by the user, by Claude, or both
Slash command
/fsdarch:scaffoldThe summary Claude sees in its command listing — used to decide when to auto-load this command
# /fsdarch:scaffold 새 슬라이스 또는 세그먼트 보일러플레이트를 생성합니다. 프로젝트 패턴을 학습하여 일관된 스타일로 코드를 생성합니다. ## Syntax ## Prerequisites - `.fsd-architect.json` 설정 파일 존재 ## Arguments | Argument | Description | Example | |----------|-------------|---------| | `layer` | FSD 레이어 (entities, features, widgets, pages) | `features` | | `slice-name` | 슬라이스 이름 | `auth` | | `segment` | (선택) 특정 세그먼트만 생성 | `ui`, `model`, `api` | ## Execution Flow ### Step 1: Validate Input 1. 레이어 유효성 검사 (sliced layer인지 확인) 2. 슬라이스 이름 검사 (기존 존재 여부) 3. **세그먼트 유효성 검사 (SECURITY CRITICAL)**: - `--segments` 플래그의 각 세그먼트에 대해 slice-genera...
/fec-scaffoldScaffolds new pages, features, or components with standard directory structures and template files. Detects project framework (React/Vue) and conventions to determine target paths.
/fire-scaffoldGuides user through multi-step wizard to scaffold features like React components, API endpoints, DB models, pages, hooks, services, tests, or custom within a phase. Supports --name, --phase, --dry-run, --minimal flags.
/erne-featureBuilds a focused feature unit like a single screen, custom hook, API module, or reusable component using the feature-builder agent, delivering complete typed code with all states, edges handled, props interface, dependencies, and integration docs.
/scaffoldScaffolds Next.js App Router pages, layouts, server/client components, API routes, server actions, and loading/error states following best practices and project patterns.
/full-stack-featureOrchestrates interactive, phased full-stack feature development across backend, frontend, database, and infrastructure layers, producing files in .full-stack-feature/ with user checkpoints.
/devkit.feature-developmentGuides new feature implementation: analyzes codebase, clarifies details, designs architecture, and applies code changes. Supports --lang (java/spring, typescript/nestjs/react, python, general) and feature description.
Share bugs, ideas, or general feedback.
새 슬라이스 또는 세그먼트 보일러플레이트를 생성합니다. 프로젝트 패턴을 학습하여 일관된 스타일로 코드를 생성합니다.
/fsdarch:scaffold <layer> <slice-name> [segment]
.fsd-architect.json 설정 파일 존재| Argument | Description | Example |
|---|---|---|
layer | FSD 레이어 (entities, features, widgets, pages) | features |
slice-name | 슬라이스 이름 | auth |
segment | (선택) 특정 세그먼트만 생성 | ui, model, api |
--segments 플래그의 각 세그먼트에 대해 slice-generator의 validateSegmentName() 호출.., /, \ 금지.으로 시작 금지^[a-zA-Z][a-zA-Z0-9-_]*$ 준수 필수Use skill: layer-detector
설정 파일에서 패턴 로드:
동일 레이어의 기존 슬라이스 분석:
Use skill: slice-generator
Naming Convention 적용
Import Style 적용
Code Style 적용
═══════════════════════════════════════════════════════════════
SLICE CREATED: auth
═══════════════════════════════════════════════════════════════
📁 Created structure:
src/features/auth/
├── index.ts # Public API
├── ui/
│ ├── index.ts
│ ├── LoginForm.tsx
│ └── LoginForm.module.css
├── model/
│ ├── index.ts
│ ├── types.ts
│ └── useAuth.ts
├── api/
│ ├── index.ts
│ └── authApi.ts
└── lib/
└── index.ts
📝 Files created: 10
🎨 Pattern applied: kebab-case, barrel exports
💡 Next steps:
1. Implement your business logic in model/
2. Create UI components in ui/
3. Define API calls in api/
4. Export public interface through index.ts
═══════════════════════════════════════════════════════════════
| Flag | Description | Example |
|---|---|---|
--segments <list> | 생성할 세그먼트 지정 | --segments ui,model,api |
--minimal | 최소 구조만 생성 (index.ts만) | --minimal |
--no-ui | UI 세그먼트 제외 | --no-ui |
--force | 기존 파일 덮어쓰기 | --force |
--dry-run | 실제 생성 없이 미리보기 | --dry-run |
src/entities/<name>/
├── index.ts # Public API
├── model/
│ ├── index.ts
│ ├── types.ts # Entity types/interfaces
│ └── store.ts # State management (if detected)
├── api/
│ ├── index.ts
│ └── <name>Api.ts # API functions
├── ui/
│ ├── index.ts
│ └── <Name>Card.tsx # Common UI component
└── lib/
└── index.ts
src/features/<name>/
├── index.ts # Public API
├── model/
│ ├── index.ts
│ ├── types.ts
│ └── use<Name>.ts # Feature hook
├── api/
│ ├── index.ts
│ └── <name>Api.ts
├── ui/
│ ├── index.ts
│ └── <Name>Button.tsx
└── lib/
└── index.ts
src/widgets/<name>/
├── index.ts # Public API
├── ui/
│ ├── index.ts
│ └── <Name>Widget.tsx
└── model/
├── index.ts
└── use<Name>Widget.ts
src/pages/<name>/
├── index.ts # Public API
└── ui/
├── index.ts
└── <Name>Page.tsx
생성 시 다음 변수가 자동 치환됩니다:
| Variable | Example Input | kebab-case | PascalCase | camelCase |
|---|---|---|---|---|
<name> | user-profile | user-profile | UserProfile | userProfile |
<Name> | user-profile | - | UserProfile | - |
[E301] Slice already exists
'auth' already exists in features layer.
Use --force to overwrite (WARNING: destructive)
Or choose a different name.
[E302] Invalid layer for scaffolding
'app' layer is not sliced. Cannot create slices in app layer.
Available sliced layers: pages, widgets, features, entities
[E303] Invalid slice name
Slice name 'my slice' contains invalid characters.
Use kebab-case, camelCase, or PascalCase without spaces.
[E305] Segment Path Traversal Attempt Blocked
Segment name '../../etc' contains forbidden characters.
Security Policy:
- '..' sequences are blocked (directory traversal)
- '/' and '\' are blocked (path separators)
- Names starting with '.' are blocked (hidden files)
Valid segment names: ui, model, api, lib, config
Invalid segment names: ../malicious, ui/nested, .hidden
/fsdarch:scaffold features auth
> Analyzing existing feature patterns...
> Detected: kebab-case, TypeScript, React Query
> Creating slice: src/features/auth/
> Created 10 files
/fsdarch:scaffold entities user --segments model,api
> Creating minimal entity slice...
> Created: src/entities/user/
> - index.ts
> - model/index.ts, types.ts
> - api/index.ts, userApi.ts
/fsdarch:scaffold widgets header --dry-run
> DRY RUN - No files will be created
Would create:
src/widgets/header/
├── index.ts
├── ui/
│ ├── index.ts
│ └── HeaderWidget.tsx
└── model/
├── index.ts
└── useHeaderWidget.ts
/fsdarch:scaffold features auth api
> Adding segment to existing slice...
> Created: src/features/auth/api/
> - index.ts
> - authApi.ts
> Updated: src/features/auth/index.ts (added export)