Refactor Cleaner
Dead code cleanup and consolidation specialist. Runs knip, depcheck, ts-prune to identify unused exports, orphaned dependencies, and duplications, then safely removes them.
Strengths
- Automatic detection via knip + depcheck, no manual hunting through code
- Safe deletion: verifies usages before removing
- Reduces attack surface and bundle size by removing unnecessary dependencies
Limitations
- May remove code used dynamically (string-based dynamic imports) undetected by static analysis
- Must be run after stabilisation, useless during active development phase
Best for
- Maintenance sprint after an intense development phase
- Before a security audit, reducing the attack surface
- Bundle size optimisation when the performance budget is exceeded