@kood/claude-code 0.1.11 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +17 -31
- package/package.json +1 -1
- package/templates/.claude/commands/feedback.md +189 -0
- package/templates/npx/docs/commands/docs-creator.md +0 -239
- package/templates/npx/docs/commands/docs-refactor.md +0 -168
- package/templates/npx/docs/commands/git-all.md +0 -83
- package/templates/npx/docs/commands/git-session.md +0 -91
- package/templates/npx/docs/commands/git.md +0 -86
- package/templates/npx/docs/commands/lint-fix.md +0 -170
- package/templates/npx/docs/commands/lint-init.md +0 -300
- package/templates/npx/docs/commands/ts-fix.md +0 -176
- package/templates/npx/docs/skills/command-creator/LICENSE.txt +0 -202
- package/templates/npx/docs/skills/command-creator/SKILL.md +0 -245
- package/templates/npx/docs/skills/command-creator/scripts/init_command.py +0 -244
- package/templates/npx/docs/skills/command-creator/scripts/package_command.py +0 -125
- package/templates/npx/docs/skills/command-creator/scripts/quick_validate.py +0 -143
- package/templates/npx/docs/skills/skill-creator/LICENSE.txt +0 -202
- package/templates/npx/docs/skills/skill-creator/SKILL.md +0 -184
- package/templates/npx/docs/skills/skill-creator/scripts/init_skill.py +0 -303
- package/templates/npx/docs/skills/skill-creator/scripts/package_skill.py +0 -110
- package/templates/npx/docs/skills/skill-creator/scripts/quick_validate.py +0 -65
- package/templates/tanstack-start/docs/commands/docs-creator.md +0 -239
- package/templates/tanstack-start/docs/commands/docs-refactor.md +0 -168
- package/templates/tanstack-start/docs/commands/git-all.md +0 -83
- package/templates/tanstack-start/docs/commands/git-session.md +0 -91
- package/templates/tanstack-start/docs/commands/git.md +0 -86
- package/templates/tanstack-start/docs/commands/lint-fix.md +0 -170
- package/templates/tanstack-start/docs/commands/lint-init.md +0 -300
- package/templates/tanstack-start/docs/commands/ts-fix.md +0 -176
- package/templates/tanstack-start/docs/skills/command-creator/LICENSE.txt +0 -202
- package/templates/tanstack-start/docs/skills/command-creator/SKILL.md +0 -245
- package/templates/tanstack-start/docs/skills/command-creator/scripts/init_command.py +0 -244
- package/templates/tanstack-start/docs/skills/command-creator/scripts/package_command.py +0 -125
- package/templates/tanstack-start/docs/skills/command-creator/scripts/quick_validate.py +0 -143
- package/templates/tanstack-start/docs/skills/skill-creator/LICENSE.txt +0 -202
- package/templates/tanstack-start/docs/skills/skill-creator/SKILL.md +0 -184
- package/templates/tanstack-start/docs/skills/skill-creator/scripts/init_skill.py +0 -303
- package/templates/tanstack-start/docs/skills/skill-creator/scripts/package_skill.py +0 -110
- package/templates/tanstack-start/docs/skills/skill-creator/scripts/quick_validate.py +0 -65
- /package/templates/{hono/docs → .claude}/commands/docs-creator.md +0 -0
- /package/templates/{hono/docs → .claude}/commands/docs-refactor.md +0 -0
- /package/templates/{hono/docs → .claude}/commands/git-all.md +0 -0
- /package/templates/{hono/docs → .claude}/commands/git-session.md +0 -0
- /package/templates/{hono/docs → .claude}/commands/git.md +0 -0
- /package/templates/{hono/docs → .claude}/commands/lint-fix.md +0 -0
- /package/templates/{hono/docs → .claude}/commands/lint-init.md +0 -0
- /package/templates/{hono/docs → .claude}/commands/ts-fix.md +0 -0
- /package/templates/{hono/docs → .claude}/skills/command-creator/LICENSE.txt +0 -0
- /package/templates/{hono/docs → .claude}/skills/command-creator/SKILL.md +0 -0
- /package/templates/{hono/docs → .claude}/skills/command-creator/scripts/init_command.py +0 -0
- /package/templates/{hono/docs → .claude}/skills/command-creator/scripts/package_command.py +0 -0
- /package/templates/{hono/docs → .claude}/skills/command-creator/scripts/quick_validate.py +0 -0
- /package/templates/{hono/docs → .claude}/skills/skill-creator/LICENSE.txt +0 -0
- /package/templates/{hono/docs → .claude}/skills/skill-creator/SKILL.md +0 -0
- /package/templates/{hono/docs → .claude}/skills/skill-creator/scripts/init_skill.py +0 -0
- /package/templates/{hono/docs → .claude}/skills/skill-creator/scripts/package_skill.py +0 -0
- /package/templates/{hono/docs → .claude}/skills/skill-creator/scripts/quick_validate.py +0 -0
|
@@ -1,300 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: 프로젝트 분석 후 ESLint flat config 설정. Sequential Thinking 필수.
|
|
3
|
-
allowed-tools: Read, Write, Edit, Glob, Bash(npm:*, yarn:*, pnpm:*, npx:*, node:*), mcp__sequential-thinking__sequentialthinking
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Lint Init Command
|
|
7
|
-
|
|
8
|
-
프로젝트 구조를 분석하고 ESLint flat config를 설정하는 커맨드.
|
|
9
|
-
|
|
10
|
-
## CRITICAL: 필수 요구사항
|
|
11
|
-
|
|
12
|
-
| 요구사항 | 설명 |
|
|
13
|
-
|----------|------|
|
|
14
|
-
| **Sequential Thinking** | `mcp__sequential-thinking__sequentialthinking` 도구로 프로젝트 분석 |
|
|
15
|
-
| **Flat Config** | ESLint v9+ flat config (`eslint.config.js`) 사용 |
|
|
16
|
-
| **기존 설정 확인** | 기존 ESLint 설정 존재 시 사용자 확인 |
|
|
17
|
-
|
|
18
|
-
## 실행 흐름
|
|
19
|
-
|
|
20
|
-
```
|
|
21
|
-
1. Sequential Thinking으로 프로젝트 분석 시작 (최소 5단계)
|
|
22
|
-
2. 핵심 파일 수집:
|
|
23
|
-
- package.json (의존성, 스크립트)
|
|
24
|
-
- tsconfig.json (TypeScript 설정)
|
|
25
|
-
- 기존 ESLint 설정 (.eslintrc.*, eslint.config.*)
|
|
26
|
-
3. 프로젝트 특성 파악:
|
|
27
|
-
- 언어: TypeScript / JavaScript
|
|
28
|
-
- 런타임: Node.js / Browser / 둘 다
|
|
29
|
-
- 프레임워크: React, Vue, Next.js, Express 등
|
|
30
|
-
4. 적절한 ESLint 설정 생성
|
|
31
|
-
5. 필요 패키지 목록 제공
|
|
32
|
-
6. 설치 명령어 안내
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
## Sequential Thinking 단계
|
|
36
|
-
|
|
37
|
-
```
|
|
38
|
-
thought 1: package.json 분석 - 의존성에서 프레임워크/라이브러리 파악
|
|
39
|
-
thought 2: tsconfig.json 분석 - TypeScript 설정 확인
|
|
40
|
-
thought 3: 디렉토리 구조 분석 - src/, app/, pages/ 등 패턴 파악
|
|
41
|
-
thought 4: 기존 ESLint 설정 확인 - 마이그레이션 필요 여부 판단
|
|
42
|
-
thought 5: 최적 ESLint 설정 결정 - 감지된 특성에 맞는 규칙 선택
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
## 프로젝트 특성 감지
|
|
46
|
-
|
|
47
|
-
### 언어 감지
|
|
48
|
-
|
|
49
|
-
| 파일/설정 | 판단 |
|
|
50
|
-
|-----------|------|
|
|
51
|
-
| `tsconfig.json` 존재 | TypeScript |
|
|
52
|
-
| `devDependencies.typescript` | TypeScript |
|
|
53
|
-
| `*.ts`, `*.tsx` 파일 | TypeScript |
|
|
54
|
-
| 그 외 | JavaScript |
|
|
55
|
-
|
|
56
|
-
### 프레임워크 감지
|
|
57
|
-
|
|
58
|
-
| 의존성 | 프레임워크 |
|
|
59
|
-
|--------|-----------|
|
|
60
|
-
| `react`, `react-dom` | React |
|
|
61
|
-
| `next` | Next.js |
|
|
62
|
-
| `vue` | Vue |
|
|
63
|
-
| `@angular/core` | Angular |
|
|
64
|
-
| `express` | Express |
|
|
65
|
-
| `hono` | Hono |
|
|
66
|
-
| `fastify` | Fastify |
|
|
67
|
-
|
|
68
|
-
### 런타임 감지
|
|
69
|
-
|
|
70
|
-
| 조건 | 런타임 |
|
|
71
|
-
|------|--------|
|
|
72
|
-
| `express`, `fastify`, `hono` | Node.js |
|
|
73
|
-
| `react`, `vue`, `angular` | Browser |
|
|
74
|
-
| `next`, `nuxt` | 둘 다 |
|
|
75
|
-
| `package.json` type: "module" | ESM |
|
|
76
|
-
|
|
77
|
-
## ESLint Flat Config 템플릿
|
|
78
|
-
|
|
79
|
-
### TypeScript + Node.js
|
|
80
|
-
|
|
81
|
-
```javascript
|
|
82
|
-
import eslint from '@eslint/js';
|
|
83
|
-
import tseslint from '@typescript-eslint/eslint-plugin';
|
|
84
|
-
import tsparser from '@typescript-eslint/parser';
|
|
85
|
-
import globals from 'globals';
|
|
86
|
-
|
|
87
|
-
export default [
|
|
88
|
-
{
|
|
89
|
-
ignores: ['dist/**', 'node_modules/**'],
|
|
90
|
-
},
|
|
91
|
-
eslint.configs.recommended,
|
|
92
|
-
{
|
|
93
|
-
files: ['src/**/*.ts'],
|
|
94
|
-
languageOptions: {
|
|
95
|
-
parser: tsparser,
|
|
96
|
-
parserOptions: {
|
|
97
|
-
ecmaVersion: 'latest',
|
|
98
|
-
sourceType: 'module',
|
|
99
|
-
project: './tsconfig.json',
|
|
100
|
-
},
|
|
101
|
-
globals: {
|
|
102
|
-
...globals.node,
|
|
103
|
-
},
|
|
104
|
-
},
|
|
105
|
-
plugins: {
|
|
106
|
-
'@typescript-eslint': tseslint,
|
|
107
|
-
},
|
|
108
|
-
rules: {
|
|
109
|
-
...tseslint.configs.recommended.rules,
|
|
110
|
-
'@typescript-eslint/explicit-function-return-type': 'warn',
|
|
111
|
-
'@typescript-eslint/no-unused-vars': [
|
|
112
|
-
'error',
|
|
113
|
-
{ argsIgnorePattern: '^_', varsIgnorePattern: '^_' },
|
|
114
|
-
],
|
|
115
|
-
'@typescript-eslint/no-explicit-any': 'error',
|
|
116
|
-
'@typescript-eslint/consistent-type-imports': [
|
|
117
|
-
'error',
|
|
118
|
-
{ prefer: 'type-imports' },
|
|
119
|
-
],
|
|
120
|
-
'no-unused-vars': 'off',
|
|
121
|
-
'no-undef': 'off',
|
|
122
|
-
'prefer-const': 'error',
|
|
123
|
-
'no-var': 'error',
|
|
124
|
-
eqeqeq: ['error', 'always'],
|
|
125
|
-
},
|
|
126
|
-
},
|
|
127
|
-
];
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
### TypeScript + React
|
|
131
|
-
|
|
132
|
-
```javascript
|
|
133
|
-
import eslint from '@eslint/js';
|
|
134
|
-
import tseslint from '@typescript-eslint/eslint-plugin';
|
|
135
|
-
import tsparser from '@typescript-eslint/parser';
|
|
136
|
-
import reactPlugin from 'eslint-plugin-react';
|
|
137
|
-
import reactHooksPlugin from 'eslint-plugin-react-hooks';
|
|
138
|
-
import globals from 'globals';
|
|
139
|
-
|
|
140
|
-
export default [
|
|
141
|
-
{
|
|
142
|
-
ignores: ['dist/**', 'node_modules/**', 'build/**'],
|
|
143
|
-
},
|
|
144
|
-
eslint.configs.recommended,
|
|
145
|
-
{
|
|
146
|
-
files: ['src/**/*.{ts,tsx}'],
|
|
147
|
-
languageOptions: {
|
|
148
|
-
parser: tsparser,
|
|
149
|
-
parserOptions: {
|
|
150
|
-
ecmaVersion: 'latest',
|
|
151
|
-
sourceType: 'module',
|
|
152
|
-
project: './tsconfig.json',
|
|
153
|
-
ecmaFeatures: {
|
|
154
|
-
jsx: true,
|
|
155
|
-
},
|
|
156
|
-
},
|
|
157
|
-
globals: {
|
|
158
|
-
...globals.browser,
|
|
159
|
-
},
|
|
160
|
-
},
|
|
161
|
-
plugins: {
|
|
162
|
-
'@typescript-eslint': tseslint,
|
|
163
|
-
'react': reactPlugin,
|
|
164
|
-
'react-hooks': reactHooksPlugin,
|
|
165
|
-
},
|
|
166
|
-
settings: {
|
|
167
|
-
react: {
|
|
168
|
-
version: 'detect',
|
|
169
|
-
},
|
|
170
|
-
},
|
|
171
|
-
rules: {
|
|
172
|
-
...tseslint.configs.recommended.rules,
|
|
173
|
-
...reactPlugin.configs.recommended.rules,
|
|
174
|
-
...reactHooksPlugin.configs.recommended.rules,
|
|
175
|
-
'@typescript-eslint/no-unused-vars': [
|
|
176
|
-
'error',
|
|
177
|
-
{ argsIgnorePattern: '^_', varsIgnorePattern: '^_' },
|
|
178
|
-
],
|
|
179
|
-
'@typescript-eslint/no-explicit-any': 'error',
|
|
180
|
-
'react/react-in-jsx-scope': 'off',
|
|
181
|
-
'react/prop-types': 'off',
|
|
182
|
-
'no-unused-vars': 'off',
|
|
183
|
-
'no-undef': 'off',
|
|
184
|
-
},
|
|
185
|
-
},
|
|
186
|
-
];
|
|
187
|
-
```
|
|
188
|
-
|
|
189
|
-
### JavaScript + Node.js
|
|
190
|
-
|
|
191
|
-
```javascript
|
|
192
|
-
import eslint from '@eslint/js';
|
|
193
|
-
import globals from 'globals';
|
|
194
|
-
|
|
195
|
-
export default [
|
|
196
|
-
{
|
|
197
|
-
ignores: ['dist/**', 'node_modules/**'],
|
|
198
|
-
},
|
|
199
|
-
eslint.configs.recommended,
|
|
200
|
-
{
|
|
201
|
-
files: ['src/**/*.js'],
|
|
202
|
-
languageOptions: {
|
|
203
|
-
ecmaVersion: 'latest',
|
|
204
|
-
sourceType: 'module',
|
|
205
|
-
globals: {
|
|
206
|
-
...globals.node,
|
|
207
|
-
},
|
|
208
|
-
},
|
|
209
|
-
rules: {
|
|
210
|
-
'no-unused-vars': [
|
|
211
|
-
'error',
|
|
212
|
-
{ argsIgnorePattern: '^_', varsIgnorePattern: '^_' },
|
|
213
|
-
],
|
|
214
|
-
'prefer-const': 'error',
|
|
215
|
-
'no-var': 'error',
|
|
216
|
-
eqeqeq: ['error', 'always'],
|
|
217
|
-
},
|
|
218
|
-
},
|
|
219
|
-
];
|
|
220
|
-
```
|
|
221
|
-
|
|
222
|
-
## 필요 패키지
|
|
223
|
-
|
|
224
|
-
### 기본 (모든 프로젝트)
|
|
225
|
-
|
|
226
|
-
```bash
|
|
227
|
-
npm install -D eslint @eslint/js globals
|
|
228
|
-
```
|
|
229
|
-
|
|
230
|
-
### TypeScript 추가
|
|
231
|
-
|
|
232
|
-
```bash
|
|
233
|
-
npm install -D @typescript-eslint/parser @typescript-eslint/eslint-plugin
|
|
234
|
-
```
|
|
235
|
-
|
|
236
|
-
### React 추가
|
|
237
|
-
|
|
238
|
-
```bash
|
|
239
|
-
npm install -D eslint-plugin-react eslint-plugin-react-hooks
|
|
240
|
-
```
|
|
241
|
-
|
|
242
|
-
### Vue 추가
|
|
243
|
-
|
|
244
|
-
```bash
|
|
245
|
-
npm install -D eslint-plugin-vue vue-eslint-parser
|
|
246
|
-
```
|
|
247
|
-
|
|
248
|
-
## 기존 설정 처리
|
|
249
|
-
|
|
250
|
-
### .eslintrc.* 마이그레이션
|
|
251
|
-
|
|
252
|
-
기존 `.eslintrc.json`, `.eslintrc.js` 등 발견 시:
|
|
253
|
-
1. 사용자에게 마이그레이션 제안
|
|
254
|
-
2. 기존 규칙을 flat config 형식으로 변환
|
|
255
|
-
3. 기존 파일 백업 후 삭제
|
|
256
|
-
|
|
257
|
-
### package.json eslintConfig
|
|
258
|
-
|
|
259
|
-
`package.json` 내 `eslintConfig` 발견 시:
|
|
260
|
-
1. 해당 설정을 flat config로 변환
|
|
261
|
-
2. `package.json`에서 `eslintConfig` 제거
|
|
262
|
-
|
|
263
|
-
## package.json 스크립트
|
|
264
|
-
|
|
265
|
-
설정 완료 후 추가할 스크립트:
|
|
266
|
-
|
|
267
|
-
```json
|
|
268
|
-
{
|
|
269
|
-
"scripts": {
|
|
270
|
-
"lint": "eslint .",
|
|
271
|
-
"lint:fix": "eslint . --fix"
|
|
272
|
-
}
|
|
273
|
-
}
|
|
274
|
-
```
|
|
275
|
-
|
|
276
|
-
## 체크리스트
|
|
277
|
-
|
|
278
|
-
### 분석 단계
|
|
279
|
-
|
|
280
|
-
- [ ] package.json 읽기
|
|
281
|
-
- [ ] tsconfig.json 확인
|
|
282
|
-
- [ ] 기존 ESLint 설정 확인
|
|
283
|
-
- [ ] 디렉토리 구조 파악
|
|
284
|
-
- [ ] 소스 파일 패턴 확인
|
|
285
|
-
|
|
286
|
-
### 설정 단계
|
|
287
|
-
|
|
288
|
-
- [ ] 적절한 템플릿 선택
|
|
289
|
-
- [ ] ignores 패턴 설정
|
|
290
|
-
- [ ] 파일 패턴 (files) 설정
|
|
291
|
-
- [ ] globals 설정
|
|
292
|
-
- [ ] 규칙 커스터마이징
|
|
293
|
-
|
|
294
|
-
### 완료 단계
|
|
295
|
-
|
|
296
|
-
- [ ] eslint.config.js 생성
|
|
297
|
-
- [ ] 필요 패키지 목록 제공
|
|
298
|
-
- [ ] 설치 명령어 안내
|
|
299
|
-
- [ ] package.json 스크립트 추가 제안
|
|
300
|
-
- [ ] 테스트 실행 안내
|
|
@@ -1,176 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: tsc 타입 오류 검사 및 하나씩 꼼꼼히 수정. ultrathink + sequential thinking 필수 사용.
|
|
3
|
-
allowed-tools: Bash(tsc:*, npx:*, yarn:*, npm:*, pnpm:*), Read, Edit, mcp__sequential-thinking__sequentialthinking
|
|
4
|
-
argument-hint: [파일/디렉토리 경로...]
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# TypeScript Fix Command
|
|
8
|
-
|
|
9
|
-
tsc 타입 오류만 검사하고 하나씩 꼼꼼히 수정하는 커맨드.
|
|
10
|
-
|
|
11
|
-
## CRITICAL: 필수 요구사항
|
|
12
|
-
|
|
13
|
-
| 요구사항 | 설명 |
|
|
14
|
-
|----------|------|
|
|
15
|
-
| **Ultrathink** | 깊은 사고로 오류 분석. 급하게 수정하지 않음 |
|
|
16
|
-
| **Sequential Thinking** | `mcp__sequential-thinking__sequentialthinking` 도구 필수 사용 |
|
|
17
|
-
| **하나씩 수정** | 한 번에 하나의 오류만 집중. 여러 오류 동시 수정 금지 |
|
|
18
|
-
|
|
19
|
-
## 실행 흐름
|
|
20
|
-
|
|
21
|
-
```
|
|
22
|
-
1. tsc --noEmit 실행 → 타입 오류 수집
|
|
23
|
-
2. 오류 목록 정리 → TodoWrite로 추적
|
|
24
|
-
3. 각 오류마다:
|
|
25
|
-
a. Sequential Thinking으로 원인 분석 (최소 3단계)
|
|
26
|
-
b. 오류의 근본 원인 파악
|
|
27
|
-
c. 안전한 수정 방안 도출
|
|
28
|
-
d. 수정 적용
|
|
29
|
-
e. 수정 후 해당 파일 재검사
|
|
30
|
-
4. 모든 오류 수정 완료 후 전체 재검사
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
## Sequential Thinking 사용법
|
|
34
|
-
|
|
35
|
-
**각 오류마다 반드시 Sequential Thinking 실행:**
|
|
36
|
-
|
|
37
|
-
```
|
|
38
|
-
오류 분석 시:
|
|
39
|
-
- thoughtNumber: 1 → 오류 메시지 분석 및 이해
|
|
40
|
-
- thoughtNumber: 2 → 관련 코드 컨텍스트 파악
|
|
41
|
-
- thoughtNumber: 3 → 근본 원인 식별
|
|
42
|
-
- thoughtNumber: 4 → 수정 방안 검토 (여러 옵션 고려)
|
|
43
|
-
- thoughtNumber: 5 → 최적 수정 방안 선택 및 적용
|
|
44
|
-
```
|
|
45
|
-
|
|
46
|
-
**Sequential Thinking 파라미터:**
|
|
47
|
-
|
|
48
|
-
| 파라미터 | 설명 |
|
|
49
|
-
|----------|------|
|
|
50
|
-
| `thought` | 현재 사고 내용 |
|
|
51
|
-
| `nextThoughtNeeded` | 추가 분석 필요 여부 |
|
|
52
|
-
| `thoughtNumber` | 현재 단계 번호 |
|
|
53
|
-
| `totalThoughts` | 예상 총 단계 (동적 조정 가능) |
|
|
54
|
-
|
|
55
|
-
## 오류 검사 명령어
|
|
56
|
-
|
|
57
|
-
```bash
|
|
58
|
-
# npm/yarn/pnpm 프로젝트
|
|
59
|
-
npx tsc --noEmit
|
|
60
|
-
|
|
61
|
-
# 특정 파일만
|
|
62
|
-
npx tsc --noEmit $ARGUMENTS
|
|
63
|
-
```
|
|
64
|
-
|
|
65
|
-
## 수정 원칙
|
|
66
|
-
|
|
67
|
-
### DO
|
|
68
|
-
|
|
69
|
-
- 오류 메시지를 정확히 이해
|
|
70
|
-
- 관련 코드 전체를 파악
|
|
71
|
-
- 타입 정의, 인터페이스 확인
|
|
72
|
-
- 제네릭 타입 파라미터 추적
|
|
73
|
-
- import된 타입 출처 확인
|
|
74
|
-
- 수정 전후 비교 분석
|
|
75
|
-
- 수정이 다른 곳에 영향 주는지 확인
|
|
76
|
-
|
|
77
|
-
### DON'T
|
|
78
|
-
|
|
79
|
-
- 오류 메시지만 보고 급하게 수정
|
|
80
|
-
- `any` 타입으로 회피
|
|
81
|
-
- `// @ts-ignore` 추가
|
|
82
|
-
- `// @ts-expect-error` 남용
|
|
83
|
-
- `as unknown as T` 강제 캐스팅
|
|
84
|
-
- 여러 오류 한 번에 수정
|
|
85
|
-
|
|
86
|
-
## 주요 타입 오류 유형
|
|
87
|
-
|
|
88
|
-
| 코드 | 설명 | 일반적 원인 |
|
|
89
|
-
|------|------|-------------|
|
|
90
|
-
| TS2322 | 할당 불가 | 타입 불일치 |
|
|
91
|
-
| TS2345 | 인수 타입 오류 | 함수 호출 시 타입 불일치 |
|
|
92
|
-
| TS2339 | 속성 없음 | 객체에 해당 속성 미존재 |
|
|
93
|
-
| TS2304 | 이름 찾을 수 없음 | import 누락 또는 오타 |
|
|
94
|
-
| TS2769 | 오버로드 매칭 실패 | 함수 시그니처 불일치 |
|
|
95
|
-
| TS2741 | 필수 속성 누락 | 객체 리터럴에 속성 누락 |
|
|
96
|
-
| TS2532 | undefined 가능성 | null/undefined 체크 필요 |
|
|
97
|
-
|
|
98
|
-
## 예시 워크플로우
|
|
99
|
-
|
|
100
|
-
```
|
|
101
|
-
1. "npx tsc --noEmit" 실행
|
|
102
|
-
→ TS2322: Type 'string' is not assignable to type 'number'
|
|
103
|
-
|
|
104
|
-
2. Sequential Thinking 시작:
|
|
105
|
-
thought 1: "TS2322 오류. string을 number에 할당 시도"
|
|
106
|
-
thought 2: "해당 파일의 변수 타입과 값 확인 필요"
|
|
107
|
-
thought 3: "함수 반환 타입이 number인데 string 반환 중"
|
|
108
|
-
thought 4: "수정 옵션: 1) 반환값 수정 2) 타입 수정"
|
|
109
|
-
thought 5: "반환값을 올바른 number로 수정하는 것이 적절"
|
|
110
|
-
|
|
111
|
-
3. Edit으로 수정 적용
|
|
112
|
-
|
|
113
|
-
4. 해당 파일 재검사
|
|
114
|
-
→ 오류 해결 확인
|
|
115
|
-
|
|
116
|
-
5. 다음 오류로 이동
|
|
117
|
-
```
|
|
118
|
-
|
|
119
|
-
## 병렬 처리 전략
|
|
120
|
-
|
|
121
|
-
**다수 타입 오류 발견 시 Task 도구로 병렬 분석:**
|
|
122
|
-
|
|
123
|
-
```
|
|
124
|
-
오류가 5개 이상일 때:
|
|
125
|
-
1. 오류 목록 수집 후 독립적인 오류 그룹 식별
|
|
126
|
-
2. Task 도구로 각 파일/오류 그룹을 병렬 분석
|
|
127
|
-
3. 분석 결과 취합 후 순차적으로 수정 적용
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
**Task 도구 활용 예시:**
|
|
131
|
-
|
|
132
|
-
```
|
|
133
|
-
# 독립적인 파일들의 타입 오류를 병렬로 분석
|
|
134
|
-
Task 1: "src/types/user.ts의 TS2322 분석 - 인터페이스 정의와 실제 사용 비교"
|
|
135
|
-
Task 2: "src/api/client.ts의 TS2345 분석 - 함수 시그니처와 호출부 타입 확인"
|
|
136
|
-
Task 3: "src/utils/format.ts의 TS2339 분석 - 객체 속성 존재 여부 및 타입 확인"
|
|
137
|
-
|
|
138
|
-
→ 3개 Task 병렬 실행 (단일 메시지에 다중 Task 호출)
|
|
139
|
-
→ 결과 취합 후 Sequential Thinking으로 수정 순서 결정
|
|
140
|
-
→ 순차적으로 수정 적용
|
|
141
|
-
```
|
|
142
|
-
|
|
143
|
-
**병렬 처리 규칙:**
|
|
144
|
-
|
|
145
|
-
| 규칙 | 설명 |
|
|
146
|
-
|------|------|
|
|
147
|
-
| 독립성 확인 | 같은 타입/인터페이스 참조 오류는 순차 처리 |
|
|
148
|
-
| 분석만 병렬 | 수정 적용은 항상 순차적으로 |
|
|
149
|
-
| 타입 전파 주의 | 한 타입 수정이 다른 오류에 영향 줄 수 있음 |
|
|
150
|
-
| 결과 검증 | 병렬 분석 결과 충돌 시 Sequential Thinking으로 해결 |
|
|
151
|
-
|
|
152
|
-
**subagent_type 선택:**
|
|
153
|
-
|
|
154
|
-
| 유형 | 용도 |
|
|
155
|
-
|------|------|
|
|
156
|
-
| `Explore` | 타입 정의 및 사용처 탐색 |
|
|
157
|
-
| `general-purpose` | 복잡한 제네릭/조건부 타입 분석 |
|
|
158
|
-
|
|
159
|
-
**타입 의존성 그래프 고려:**
|
|
160
|
-
|
|
161
|
-
```
|
|
162
|
-
예시: UserDTO → UserService → UserController
|
|
163
|
-
↓
|
|
164
|
-
하위 타입 오류가 상위에 영향 → 하위부터 수정
|
|
165
|
-
→ 병렬 분석 시에도 의존 관계 파악 필수
|
|
166
|
-
```
|
|
167
|
-
|
|
168
|
-
## 인수 처리
|
|
169
|
-
|
|
170
|
-
| 인수 | 동작 |
|
|
171
|
-
|------|------|
|
|
172
|
-
| 없음 | 전체 프로젝트 검사 |
|
|
173
|
-
| 파일 경로 | 해당 파일만 검사 |
|
|
174
|
-
| 디렉토리 | 해당 디렉토리만 검사 |
|
|
175
|
-
|
|
176
|
-
**인수**: $ARGUMENTS
|
|
@@ -1,202 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
Apache License
|
|
3
|
-
Version 2.0, January 2004
|
|
4
|
-
http://www.apache.org/licenses/
|
|
5
|
-
|
|
6
|
-
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
-
|
|
8
|
-
1. Definitions.
|
|
9
|
-
|
|
10
|
-
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
-
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
-
|
|
13
|
-
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
-
the copyright owner that is granting the License.
|
|
15
|
-
|
|
16
|
-
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
-
other entities that control, are controlled by, or are under common
|
|
18
|
-
control with that entity. For the purposes of this definition,
|
|
19
|
-
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
-
direction or management of such entity, whether by contract or
|
|
21
|
-
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
-
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
-
|
|
24
|
-
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
-
exercising permissions granted by this License.
|
|
26
|
-
|
|
27
|
-
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
-
including but not limited to software source code, documentation
|
|
29
|
-
source, and configuration files.
|
|
30
|
-
|
|
31
|
-
"Object" form shall mean any form resulting from mechanical
|
|
32
|
-
transformation or translation of a Source form, including but
|
|
33
|
-
not limited to compiled object code, generated documentation,
|
|
34
|
-
and conversions to other media types.
|
|
35
|
-
|
|
36
|
-
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
-
Object form, made available under the License, as indicated by a
|
|
38
|
-
copyright notice that is included in or attached to the work
|
|
39
|
-
(an example is provided in the Appendix below).
|
|
40
|
-
|
|
41
|
-
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
-
form, that is based on (or derived from) the Work and for which the
|
|
43
|
-
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
-
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
-
of this License, Derivative Works shall not include works that remain
|
|
46
|
-
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
-
the Work and Derivative Works thereof.
|
|
48
|
-
|
|
49
|
-
"Contribution" shall mean any work of authorship, including
|
|
50
|
-
the original version of the Work and any modifications or additions
|
|
51
|
-
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
-
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
-
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
-
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
-
means any form of electronic, verbal, or written communication sent
|
|
56
|
-
to the Licensor or its representatives, including but not limited to
|
|
57
|
-
communication on electronic mailing lists, source code control systems,
|
|
58
|
-
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
-
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
-
excluding communication that is conspicuously marked or otherwise
|
|
61
|
-
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
-
|
|
63
|
-
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
-
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
-
subsequently incorporated within the Work.
|
|
66
|
-
|
|
67
|
-
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
-
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
-
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
-
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
-
Work and such Derivative Works in Source or Object form.
|
|
73
|
-
|
|
74
|
-
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
-
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
-
(except as stated in this section) patent license to make, have made,
|
|
78
|
-
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
-
where such license applies only to those patent claims licensable
|
|
80
|
-
by such Contributor that are necessarily infringed by their
|
|
81
|
-
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
-
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
-
institute patent litigation against any entity (including a
|
|
84
|
-
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
-
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
-
or contributory patent infringement, then any patent licenses
|
|
87
|
-
granted to You under this License for that Work shall terminate
|
|
88
|
-
as of the date such litigation is filed.
|
|
89
|
-
|
|
90
|
-
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
-
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
-
modifications, and in Source or Object form, provided that You
|
|
93
|
-
meet the following conditions:
|
|
94
|
-
|
|
95
|
-
(a) You must give any other recipients of the Work or
|
|
96
|
-
Derivative Works a copy of this License; and
|
|
97
|
-
|
|
98
|
-
(b) You must cause any modified files to carry prominent notices
|
|
99
|
-
stating that You changed the files; and
|
|
100
|
-
|
|
101
|
-
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
-
that You distribute, all copyright, patent, trademark, and
|
|
103
|
-
attribution notices from the Source form of the Work,
|
|
104
|
-
excluding those notices that do not pertain to any part of
|
|
105
|
-
the Derivative Works; and
|
|
106
|
-
|
|
107
|
-
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
-
distribution, then any Derivative Works that You distribute must
|
|
109
|
-
include a readable copy of the attribution notices contained
|
|
110
|
-
within such NOTICE file, excluding those notices that do not
|
|
111
|
-
pertain to any part of the Derivative Works, in at least one
|
|
112
|
-
of the following places: within a NOTICE text file distributed
|
|
113
|
-
as part of the Derivative Works; within the Source form or
|
|
114
|
-
documentation, if provided along with the Derivative Works; or,
|
|
115
|
-
within a display generated by the Derivative Works, if and
|
|
116
|
-
wherever such third-party notices normally appear. The contents
|
|
117
|
-
of the NOTICE file are for informational purposes only and
|
|
118
|
-
do not modify the License. You may add Your own attribution
|
|
119
|
-
notices within Derivative Works that You distribute, alongside
|
|
120
|
-
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
-
that such additional attribution notices cannot be construed
|
|
122
|
-
as modifying the License.
|
|
123
|
-
|
|
124
|
-
You may add Your own copyright statement to Your modifications and
|
|
125
|
-
may provide additional or different license terms and conditions
|
|
126
|
-
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
-
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
-
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
-
the conditions stated in this License.
|
|
130
|
-
|
|
131
|
-
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
-
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
-
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
-
this License, without any additional terms or conditions.
|
|
135
|
-
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
-
the terms of any separate license agreement you may have executed
|
|
137
|
-
with Licensor regarding such Contributions.
|
|
138
|
-
|
|
139
|
-
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
-
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
-
except as required for reasonable and customary use in describing the
|
|
142
|
-
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
-
|
|
144
|
-
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
-
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
-
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
-
implied, including, without limitation, any warranties or conditions
|
|
149
|
-
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
-
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
-
appropriateness of using or redistributing the Work and assume any
|
|
152
|
-
risks associated with Your exercise of permissions under this License.
|
|
153
|
-
|
|
154
|
-
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
-
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
-
unless required by applicable law (such as deliberate and grossly
|
|
157
|
-
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
-
liable to You for damages, including any direct, indirect, special,
|
|
159
|
-
incidental, or consequential damages of any character arising as a
|
|
160
|
-
result of this License or out of the use or inability to use the
|
|
161
|
-
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
-
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
-
other commercial damages or losses), even if such Contributor
|
|
164
|
-
has been advised of the possibility of such damages.
|
|
165
|
-
|
|
166
|
-
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
-
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
-
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
-
or other liability obligations and/or rights consistent with this
|
|
170
|
-
License. However, in accepting such obligations, You may act only
|
|
171
|
-
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
-
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
-
defend, and hold each Contributor harmless for any liability
|
|
174
|
-
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
-
of your accepting any such warranty or additional liability.
|
|
176
|
-
|
|
177
|
-
END OF TERMS AND CONDITIONS
|
|
178
|
-
|
|
179
|
-
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
-
|
|
181
|
-
To apply the Apache License to your work, attach the following
|
|
182
|
-
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
-
replaced with your own identifying information. (Don't include
|
|
184
|
-
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
-
comment syntax for the file format. We also recommend that a
|
|
186
|
-
file or class name and description of purpose be included on the
|
|
187
|
-
same "printed page" as the copyright notice for easier
|
|
188
|
-
identification within third-party archives.
|
|
189
|
-
|
|
190
|
-
Copyright [yyyy] [name of copyright owner]
|
|
191
|
-
|
|
192
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
-
you may not use this file except in compliance with the License.
|
|
194
|
-
You may obtain a copy of the License at
|
|
195
|
-
|
|
196
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
-
|
|
198
|
-
Unless required by applicable law or agreed to in writing, software
|
|
199
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
-
See the License for the specific language governing permissions and
|
|
202
|
-
limitations under the License.
|