Skip to content

[feat] Add knip for unused code detection #4890

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Aug 12, 2025
Merged

[feat] Add knip for unused code detection #4890

merged 8 commits into from
Aug 12, 2025

Conversation

huchenlei
Copy link
Collaborator

@huchenlei huchenlei commented Aug 10, 2025

Summary

  • Add knip to detect unused files, exports, and dependencies
  • Configure knip with minimal rules (unused files only initially)
  • Add knip to CI pipeline for automated checks
  • Add npm scripts for running knip locally

Related Issues

Tracks gradual enablement of additional knip rules: #4888
Continued on #4886

┆Issue is synchronized with this Notion page by Unito

@huchenlei huchenlei requested a review from a team as a code owner August 10, 2025 02:39
Copy link

socket-security bot commented Aug 10, 2025

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addedknip@​5.62.0981009293100

View full report

Copy link
Contributor

@christian-byrne christian-byrne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@christian-byrne christian-byrne merged commit c7baf3c into main Aug 12, 2025
13 checks passed
@christian-byrne christian-byrne deleted the knip branch August 12, 2025 02:23
@christian-byrne christian-byrne mentioned this pull request Aug 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants