clean-code

Identify SOLID/KISS violations in code samples and suggest concise alternatives.

Updated Jul 15, 2025
One-click install
npx skills add https://github.com/nicolas-deyros/astro-portfolio-v2 --skill clean-code-nicolas-deyros
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: clean-code
Source: https://github.com/nicolas-deyros/astro-portfolio-v2/tree/main/.agents/skills/clean-code
Command: npx skills add https://github.com/nicolas-deyros/astro-portfolio-v2 --skill clean-code-nicolas-deyros

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Pragmatic coding standards to keep code concise, direct, and maintainable, preventing over-engineering and excessive commentary.

Core Features & Use Cases

  • Enforces single-responsibility and minimalism to improve readability
  • Promotes guard clauses, early exits, and flat structures to reduce complexity
  • Provides naming, function design, and error-handling guidelines for faster collaboration
  • Defines AI coding style rules for feature development and debugging

Quick Start

Apply the clean-code guidelines to a sample function and produce a refactored, concise version.

Frequently Asked Questions about clean-code

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I refactor code to follow SOLID and KISS principles?

Refactoring code for SOLID and KISS principles involves identifying violations like complex functions and excessive commentary, then applying guard clauses, early exits, and flat structures to produce a concise, maintainable result.

What are the best coding standards for improving code readability and collaboration?

Coding standards for readability and collaboration enforce single-responsibility, minimalism, naming conventions, and function design guidelines, reducing complexity and over-engineering for faster team collaboration.

How do I apply guard clauses and early exits to reduce code complexity?

Applying guard clauses and early exits reduces code complexity by enforcing flat structures and minimalism, identifying nested patterns that violate KISS principles, and suggesting concise alternatives for cleaner function design.

Can I use these clean code guidelines across different programming languages?

Yes, these clean code guidelines are applicable to software projects across languages, focusing on universal patterns like naming, error handling, and function design rather than language-specific syntax.

Why should I use pragmatic coding standards to prevent over-engineering?

Pragmatic coding standards prevent over-engineering by enforcing minimalism and single-responsibility, ensuring code remains concise, direct, and maintainable without excessive commentary or unnecessary abstractions.

How do I identify naming conventions and error handling patterns that violate clean code?

Identifying naming and error handling violations involves analyzing a given code sample against coding standards, detecting patterns that break single-responsibility, and suggesting concise, testable alternatives.