AI AGENT ADDONS

Component Refactoring

langgenius/dify

This tool helps you clean up messy React components. It focuses on components that are too big or complex. You can use it to make your code easier to read and maintain.

The tool checks two main things: a complexity score and the number of lines. If the score is above 50 or the file has more than 300 lines, it is time to refactor. You can run commands to see these numbers.

Two common ways to refactor are extracting custom hooks and splitting into smaller components. These patterns keep your code simple and organized. The guide shows real examples from the Dify frontend.

Add Component Refactoring skill to your workflow

Global

mkdir -p ~/.claude/skills/component-refactoring

Project

mkdir -p .claude/skills/component-refactoring

Source Repository

Stars
146,852
Forks
23,135
Watchers
146,852
License
NOASSERTION
Last Push
1 month ago
Created
3 years ago