← Back to list

typescript-reviewer
by gregsuptown
⭐ 0🍴 0📅 Jan 10, 2026
SKILL.md
name: typescript-reviewer description: Review TypeScript code for type safety, null safety, and modern patterns. Enforces Studio-535 standards - no lazy any types, service layer pattern, proper error handling. Use when reviewing .ts/.tsx files or checking type definitions. allowed-tools: Read, Grep, Glob
TypeScript Best Practices Reviewer
Standards
Type Safety
- ❌ No
anytypes without explicit justification comment - ✅ Use
unknownfor truly unknown data - ✅ Proper generic constraints
Null Safety
- ✅ Use optional chaining
?.and nullish coalescing?? - ✅ Explicit undefined handling in function returns
- ❌ No loose equality checks (
==instead use===)
React Components
- ✅ Prop types defined with interface or type
- ✅ Event handlers typed properly (React.ChangeEvent, etc.)
- ✅ Hooks dependency arrays complete
Service Layer Pattern
- ✅ Business logic in
server/services/ - ❌ NO business logic in routers
- ✅ Routers only: validation, auth, service calls
Error Handling
- ✅ Use discriminated unions for error returns
- ✅ Typed error responses in tRPC procedures
- ❌ No throwing raw strings
Review Checklist
When reviewing a file:
- Check for
anytypes - flag and suggest proper type - Verify null/undefined handling
- Validate React hook dependencies if component
- Ensure service layer pattern if in server/
- Check error handling in tRPC procedures
Example Feedback Format
## Type Safety Issues
### File: server/routers.ts:45
- ❌ Using `any` for user parameter
- ✅ Suggested: `user: { id: string; email: string }`
### File: client/src/components/Form.tsx:22
- ❌ Missing dependency in useEffect: `userId`
- ✅ Add to dependency array: `[userId, fetchData]`
Auto-Invocation Triggers
This Skill should activate when:
- Reviewing changes to
.tsor.tsxfiles - User asks to "review TypeScript code"
- User asks to "check types" or "improve type safety"
- PR review requested
Score
Total Score
50/100
Based on repository quality metrics
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
Reviews
💬
Reviews coming soon