About deslop
deslop is a code-review skill for developers who want to remove unnecessary patterns introduced in a branch. It compares the diff with main and favors focused edits that preserve behavior.
Key features
- 01Review branch diff against main
- 02Remove unnecessary comments and checks
- 03Replace type escape hatches
- 04Simplify nesting and one-use definitions
- 05Keep behavior unchanged with focused edits
Use cases
- 01Clean up generated code before merging a branch
- 02Align edits with the surrounding code style
Install
Copy the command and run it in a terminal.
$
npx skills add https:/ / github.com/ ilamanov/ skills --skill deslopAfter installing, type/deslopin Claude Code to confirm it loaded.
Details
From the project READMERemove AI code slop
Check the diff against main and remove AI-generated slop introduced in the branch.
Focus Areas
- Unnecessary comments - Extra comments that are unnecessary or inconsistent with local style
- Defensive overkill - Defensive checks or try/catch blocks that are abnormal for trusted code paths
- Type escape hatches - Casts to
anyused only to bypass type issues - Deep nesting - Deeply nested code that should be simplified with early returns
- Single-use variables - Variables used once immediately after declaration; inline the RHS instead
- Single-use type definitions - Separate type or interface definitions used in only one place (React props, function parameters, return types, etc.); inline the type directly where it's used
- Re-exports from another file - There should be exactly one export of a thing, in the file that defines it. Don't re-export something defined elsewhere — whether the file is a pure barrel/pass-through or does real work alongside the re-exports. Drop the re-export lines and point importers at the defining module.
- Style drift - Other patterns inconsistent with the file and surrounding codebase
Guardrails
- Keep behavior unchanged unless fixing a clear bug.
- Prefer minimal, focused edits over broad rewrites.
- Keep the final summary concise (1-3 sentences).
Comments
Markdown supported