askill
knip

knipSafety 75Repository

Finds unused dependencies, files, and exports in JS/TS projects. Use when cleaning up dead code, removing stale packages from package.json, or identifying unreferenced exports.

3 stars
1.2k downloads
Updated 2/7/2026

Package Files

Loading files...
SKILL.md

Knip

Finds unused files, dependencies, and exports in TypeScript/JavaScript projects.

Usage

bunx knip                     # Analyze project
bunx knip --production        # Production only (no tests, devDeps)
bunx knip --strict            # Direct dependencies only
bunx knip --fix               # Auto-remove unused (use cautiously)
bunx knip --include files     # Only unused files
bunx knip --include exports   # Only unused exports
bunx knip --include dependencies  # Only unused deps

Output Formats

bunx knip --reporter compact  # Compact output
bunx knip --reporter json     # JSON for tooling
bunx knip --reporter github-actions  # CI annotations

Filtering

bunx knip --workspace packages/client  # Specific workspace
bunx knip --exclude "test/**/*"        # Exclude patterns

Debugging

bunx knip --debug                      # Debug output
bunx knip --trace-file src/utils.ts    # Trace file
bunx knip --trace-export myFunction    # Trace export

Configuration

Configure via .knip.json or knip.config.js for custom entry points and exclusions.

Related Skills

  • maintenance: Refactoring and technical debt management
  • jscpd: Find duplicate code blocks
  • bun: Package management for JS/TS projects

Install

Download ZIP
Requires askill CLI v1.0+

AI Quality Score

88/100Analyzed 2/16/2026

Well-structured reference skill for Knip with clear commands and good organization. Practical and reusable across JS/TS projects.

75
90
90
85
90

Metadata

Licenseunknown
Version-
Updated2/7/2026
Publisherknoopx

Tags

ci-cdgithubtesting