Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
There was a problem hiding this comment.
Pull request overview
This PR integrates Knip into the repository’s CI pipeline to detect unused files/exports/dependencies, and adjusts code/config so Knip can run cleanly in this monorepo setup.
Changes:
- Run
knipas part of the rootnpm run ciworkflow. - Update
knip.jsonwith stricter settings and multiple ignore rules to reduce false positives. - Remove unused Dashboard components that would otherwise be flagged by Knip.
Reviewed changes
Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/dashboard/src/components/status-badge.tsx | Removes an unused StatusBadge component. |
| packages/dashboard/src/components/stats-card.tsx | Removes an unused StatsCard component. |
| package.json | Adds npm run knip into the ci script pipeline. |
| package-lock.json | Lockfile updates (appears to be regeneration/metadata changes). |
| knip.json | Tightens Knip config and adds ignore rules to make CI pass. |
| "ignoreFiles": [ | ||
| "**/openworkflow.config.*", | ||
| "openworkflow/**/*.ts", | ||
| "packages/dashboard/src/components/ui/*.tsx", | ||
| "packages/docs/style.css" | ||
| ], | ||
| "ignoreIssues": { | ||
| "packages/dashboard/src/components/ui/*.tsx": ["exports"], | ||
| "packages/openworkflow/workflow.ts": ["duplicates"] |
There was a problem hiding this comment.
packages/dashboard/src/components/ui/*.tsx is listed in both ignoreFiles and ignoreIssues. If those files are ignored entirely, the ignoreIssues entry for them won’t have any effect and may hide whether the files are actually in-scope for dependency/entry analysis. Consider keeping only one of these (e.g., drop ignoreFiles if you only meant to suppress exports, or drop the ignoreIssues entry if you truly want to exclude these files).
| "ignoreBinaries": ["mint", "open"], | ||
| "ignoreDependencies": [ | ||
| "@tanstack/react-router-ssr-query", | ||
| "@tanstack/router-plugin", | ||
| "@testing-library/dom", | ||
| "@testing-library/react", | ||
| "jsdom", | ||
| "postgres", | ||
| "web-vitals" | ||
| ], |
There was a problem hiding this comment.
ignoreDependencies is configured at the top level, but the ignored packages appear to be workspace-specific (most are only in packages/dashboard/package.json, while postgres is also used elsewhere). If Knip is intended to enforce unused deps across the monorepo, consider scoping these ignores to the relevant workspace/package so they don’t mask unused-dependency findings in other workspaces that might add the same deps later.
No description provided.