새 컴포넌트·훅·유틸·타입·쿼리를 만들기 전에 기존 코드에서 유사/중복 구현을 찾아 재사용을 권한다. Use BEFORE creating anything new, or when the user says "만들어줘 / 추가해줘 / 구현해줘".
Scanned 9/9/2026
Install to Claude Code
npx -y skills add mash-up-kr/Promise.9-Web --skill check-dup --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of Check Dup?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/mash-up-kr-check-dup)More formats (shields.io, HTML) on the badges page.
---
name: check-dup
description: 새 컴포넌트·훅·유틸·타입·쿼리를 만들기 전에 기존 코드에서 유사/중복 구현을 찾아 재사용을 권한다. Use BEFORE creating anything new, or when the user says "만들어줘 / 추가해줘 / 구현해줘".
---
# check-dup — 중복 코드 방지
새 코드를 작성하기 **전에** 실행한다. 목적: 3명이 각자 AI로 개발하며 같은 걸 또 만드는 것을 막는다.
특히 **앱·웹·익스텐션이 같은 도메인(링크)을 공유**하므로 표면 간 중복이 1순위 위험이다.
## 절차
1. 만들려는 대상의 핵심 키워드 2~4개를 뽑는다 (예: "저장한 링크 카드" → link, card, list).
2. **결정 규칙(structure.md) 순서로** 검색한다:
- 먼저 `shared/` — 타입·API·도메인 로직이 이미 있나? (앱/익스텐션이 또 만들기 쉬운 곳)
- 다음 `src/features/*`, `src/components`, `src/hooks`, `src/utils`
- 익스텐션 작업이면 `extension/src/`
- 검색법: 파일명 `**/*<Keyword>*.{ts,tsx}` + 내용/시그니처 grep
3. 결과를 분류해 보고한다:
- ✅ **재사용**: 그대로 쓸 수 있는 기존 코드 → 경로 제시, 새로 만들지 않는다.
- 🔧 **확장**: 비슷하지만 부족 → 기존 것을 확장/제너럴라이즈 제안.
- 🆕 **신규**: 정말 없음 → 적절한 skill(`/new-component` 등)로 생성 진행.
4. 결정 근거를 한 줄로 남기고 사용자 확인 후 진행.
## 원칙
- 애매하면 신규 생성보다 **재사용/확장**을 우선한다.
- 순수 로직(타입·API·분류/검색)은 표면별로 중복 구현하지 말고 `shared/` 로 올린다.
- 파일 위치는 docs/conventions/structure.md 의 결정 규칙을 따른다.
Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.
No comments yet. Be the first to comment!
Use this skill when developing or maintaining browser extension code in the `browser/` directory, including Chrome/Firefox/Edge compatibility, content scripts, background scripts, or i18n updates.