emiliodominguez/flow-skills

flow-simplify

Targeted cleanup of provably dead code and accidental complexity.

소스 보기

사용 방법

  1. 설치 명령을 복사하고 자신의 에이전트 환경에 설치하기 전에 소스 패키지를 확인하세요.
  2. 필요한 도구, 인증 정보, 지원 환경은 원본 문서에서 확인하세요.
  3. 입력과 원하는 산출물을 설명하고 출처와 결과를 대조하세요.
npx skills add https://github.com/emiliodominguez/flow-skills --skill flow-simplify

시작 전 확인

  • 설치에는 모델 구독, API 한도, 파일 접근 권한이 포함되지 않습니다.
  • 별점 수와 설치 수는 활동 지표이며 독립적인 품질·보안 검증이 아닙니다.
원본 Skill 문서

원본 저장소의 제목, 예시, 코드, 표, 링크, 이미지를 유지해 표시합니다.

Simplify

Subtract only where it improves understanding without changing required behavior. Fewer lines is a possible outcome, not the acceptance criterion.

Process

  1. Bound the cleanup, establish relevant checks and preserve unrelated staged/unstaged work.

Name the concrete complexity: dead paths, needless indirection, duplicate responsibility, stale comments or generated slop.

  1. Order reduction passes by semantic risk. For large scopes, authorized read-only reviewers can

inspect disjoint areas; one writer per file. No arbitrary agent or file-count threshold.

  1. Caller-check before deleting a symbol: imports, dynamic lookup, registries, reflection,

routes, config, templates, tests, generated sources, package exports. Repository search cannot see external consumers of a published API.

  1. Mark a deletion CONFIRMED-DEAD only with usage and runtime evidence; keep uncertain

exports or negotiate the compatibility change. Keep side-effect imports (registration, polyfills) and license, compiler and tool-directive comments.

  1. Inspect single-use abstractions instead of auto-inlining. Components, Hooks, closures and

effects carry identity, state lifetime and evaluation order even with one caller.

  1. Remove a defensive guard only when input provenance proves it redundant. Static types do not

validate network, JSON, storage, DOM or JavaScript consumers.

  1. Cut in small steps, run behavior and repository checks, inspect the combined diff. Stop when

the stated complexity is resolved.

Anti-patterns

  • Net-negative lines as a quality gate, or every single-use component as waste.
  • Removing imports, comments or guards on regex or type evidence alone.
  • Deleting a public export because internal grep finds no caller.
  • Quietly changing error behavior or component state lifetime.

Done when

  • The targeted code is easier to understand with semantics and compatibility preserved.
  • Deletions have evidence; uncertain consumers remain explicit.
  • Required checks ran on the resulting artifact, not an earlier baseline.

Use flow-review for the diff or flow-refactor for a separate ownership or structure problem.

관련 작업

같은 저장소의 Skills

더 많은 Skills

모든 Skills