plan-lower-code-complexity

Lower Code Complexity

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "plan-lower-code-complexity" with this command: npx skills add codyswanngt/lisa/codyswanngt-lisa-plan-lower-code-complexity

Lower Code Complexity

Reduces the cognitive complexity threshold by 2 and fixes all violations.

Step 1: Gather Requirements

  • Read current threshold from eslint config (cognitive-complexity rule)

  • Calculate new threshold: current - 2 (e.g., 15 -> 13)

  • Run lint with the new threshold to find violations: bun run lint 2>&1 | grep "cognitive-complexity"

  • Note for each violation:

  • File path and line number

  • Function name

  • Current complexity score

If no violations at new threshold, report success and exit.

Step 2: Compile Brief and Delegate

Compile the gathered information into a structured brief:

Reduce cognitive complexity threshold from [current] to [new].

Functions exceeding threshold (ordered by complexity):

  1. [file:function] (complexity: X, target: [new]) - Line Y
  2. ...

Configuration change: [eslint config path], cognitive-complexity from [current] to [new]

Refactoring strategies: extract functions, early returns, extract conditions, use lookup tables

Verification: bun run lint 2>&1 | grep "cognitive-complexity" | wc -l → Expected: 0

Invoke /plan-execute with this brief to create the implementation plan.

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

claude-code-action

No summary provided by upstream source.

Repository SourceNeeds Review
Coding

plan-local-code-review

No summary provided by upstream source.

Repository SourceNeeds Review
General

lisa-review-project

No summary provided by upstream source.

Repository SourceNeeds Review