跳到正文
cccskills
免费在 GitHub 公开

knip-deadcode

Knip dead code detection best practices for JavaScript and TypeScript projects. Use when configuring Knip, analyzing unused code, setting up CI integration, or cleaning up codebases. Triggers on knip.json, dead code, unused exports, unused dependencies, bundle optimization.

中文简介正在准备中。当前显示原文说明。

查看安装方法

包含的文件(54)

  • SKILL.md7.8 KB
  • assets/templates/_template.md859 B
  • references/_sections.md1.8 KB
  • references/ci-add-to-pipeline.md1.0 KB
  • references/ci-separate-production-check.md1.2 KB
  • references/ci-use-cache.md942 B
  • references/ci-use-max-issues.md1.1 KB
  • references/ci-use-reporters.md1.1 KB
  • references/ci-watch-mode-local.md1.1 KB
  • references/config-avoid-broad-ignore.md1.3 KB
  • references/config-configure-path-aliases.md1.1 KB
  • references/config-enable-plugins-explicitly.md947 B
  • references/config-run-without-config.md1.1 KB
  • references/config-separate-entry-project.md948 B
  • references/config-use-json-schema.md917 B
  • references/config-use-negation-patterns.md910 B
  • references/config-use-production-mode.md1.0 KB
  • references/deps-add-unlisted-deps.md1.1 KB
  • references/deps-avoid-transitive-reliance.md1.1 KB
  • references/deps-configure-plugin-deps.md1.1 KB
  • references/deps-fix-files-first.md1.1 KB
  • references/deps-ignore-conditional-deps.md1.1 KB
  • references/deps-remove-obsolete-types.md1.1 KB
  • references/entry-add-dynamic-imports.md1.1 KB
  • references/entry-exclude-test-files.md1.0 KB
  • references/entry-include-all-entry-points.md1.0 KB
  • references/entry-include-bin-scripts.md1.0 KB
  • references/entry-use-compilers.md1.2 KB
  • references/entry-use-plugin-entries.md1013 B
  • references/entry-verify-with-debug.md1.1 KB
  • references/exports-check-class-members.md1.1 KB
  • references/exports-enable-entry-exports.md1.2 KB
  • references/exports-handle-reexports.md1.1 KB
  • references/exports-ignore-same-file.md1.1 KB
  • references/exports-tag-public-api.md1022 B
  • references/exports-trace-usage.md1.1 KB
  • references/exports-use-include-libs.md1.2 KB
  • references/fix-allow-remove-files.md1.1 KB
  • references/fix-format-after-fix.md1012 B
  • references/fix-review-before-commit.md1.1 KB
  • references/fix-update-deps-after.md1.1 KB
  • references/fix-use-fix-type.md1.1 KB
  • references/perf-filter-issue-types.md1.0 KB
  • references/perf-limit-output.md1.1 KB
  • references/perf-profile-performance.md1.1 KB
  • references/perf-use-bun-runtime.md971 B
  • references/perf-use-cache-flag.md1013 B
  • references/perf-use-workspace-filter.md1.3 KB
  • references/workspace-configure-root-workspace.md1.0 KB
  • references/workspace-ignore-specific.md1.0 KB
  • references/workspace-isolate-for-strict.md1.0 KB
  • references/workspace-list-cross-deps.md1.1 KB
  • references/workspace-per-workspace-plugins.md1.2 KB
  • references/workspace-use-workspace-globs.md1.1 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Community Knip Dead Code Detection Best Practices

Comprehensive guide for detecting and removing dead code in JavaScript and TypeScript projects using Knip. Contains 43 rules across 8 categories, prioritized by impact to guide configuration, CI integration, and cleanup workflows.

When to Apply

Reference these guidelines when:

  • Configuring Knip for a new project or monorepo
  • Investigating false positives or false negatives
  • Setting up CI pipelines to prevent dead code regressions
  • Using auto-fix to clean up unused code
  • Optimizing Knip performance for large codebases

Rule Categories by Priority

PriorityCategoryImpactPrefix
1Configuration FoundationsCRITICALconfig-
2Entry Point StrategyCRITICALentry-
3Workspace & MonorepoHIGHworkspace-
4Dependency AnalysisHIGHdeps-
5Export DetectionMEDIUM-HIGHexports-
6CI IntegrationMEDIUMci-
7Auto-Fix WorkflowMEDIUMfix-
8Performance OptimizationLOW-MEDIUMperf-

Quick Reference

1. Configuration Foundations (CRITICAL)

2. Entry Point Strategy (CRITICAL)

3. Workspace & Monorepo (HIGH)

4. Dependency Analysis (HIGH)

5. Export Detection (MEDIUM-HIGH)

6. CI Integration (MEDIUM)

7. Auto-Fix Workflow (MEDIUM)

8. Performance Optimization (LOW-MEDIUM)

How to Use

Read individual reference files for detailed explanations and code examples:

Reference Files

FileDescription
references/_sections.mdCategory definitions and ordering
assets/templates/_template.mdTemplate for new rules
metadata.jsonVersion and reference information

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Automates browser interactions for web testing, form filling, screenshots, and data extraction. Use when the user needs to navigate websites, interact with web pages, fill forms, take screenshots, test web applications, or extract information from web pages.

中文简介正在准备中。当前显示原文说明。

wordbricks/onequery172026年7月30日 更新

A scoring scale for evaluating how well a CLI is designed for AI agents, based on the "Rewrite Your CLI for AI Agents" principles.

中文简介正在准备中。当前显示原文说明。

wordbricks/onequery172026年7月30日 更新

Score a repository's agentic legibility from repo-visible evidence only. Use when Codex needs to audit how easy a codebase is for coding agents to discover, bootstrap, validate, and navigate, especially for harness-engineering reviews, developer-experience audits, repo cleanup, or before/after comparisons after improving docs, tooling, or architectural constraints.

中文简介正在准备中。当前显示原文说明。

wordbricks/onequery172026年7月30日 更新

astro

免费

Expert in Astro framework with static generation and partial hydration patterns

中文简介正在准备中。当前显示原文说明。

wordbricks/onequery172026年7月30日 更新

Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep watching open PRs so fresh review feedback is surfaced promptly. Use when the user asks Codex to monitor a PR, watch CI, handle review comments, or keep an eye on failures and feedback on an open PR.

中文简介正在准备中。当前显示原文说明。

wordbricks/onequery172026年7月30日 更新

Adopt better-result in an existing TypeScript codebase. Use when replacing try/catch, Promise rejection handling, null sentinels, or thrown domain exceptions with typed Result workflows.

中文简介正在准备中。当前显示原文说明。

wordbricks/onequery172026年7月30日 更新

查看 wordbricks 的全部技能

报告此技能的问题