clean-code

Enforces pragmatic coding standards for concise, direct, and maintainable code generation.

Updated Aug 5, 2026
One-click install
npx skills add https://github.com/pd-phuc/laravel-template --skill clean-code-pd-phuc
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: clean-code
Source: https://github.com/pd-phuc/laravel-template/tree/main/.claude/skills/clean-code
Command: npx skills add https://github.com/pd-phuc/laravel-template --skill clean-code-pd-phuc

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? AI-generated code often suffers from over-engineering, excessive comments, deep nesting, and broken cross-file dependencies. This Skill enforces pragmatic coding standards so generated code stays concise, readable, and consistent across edits. ## Core Features & Use Cases - Coding Standards Enforcement: Applies SRP, DRY, KISS, and YAGNI principles with concrete naming, function size, and structure rules. - Dependency-Aware Editing: Requires checking imports and dependents before modifying any file, preventing broken references. - Verification Workflow: Maps specialist agents to validation scripts and mandates a read-summarize-ask flow before fixing reported issues. - Use Case: When asking an AI to add a feature or fix a bug in a Laravel or TypeScript project, the Skill ensures the change is minimal, self-documenting, and all dependent files are updated in the same task. ## Quick Start Ask the AI to implement a feature or fix a bug and require it to follow the clean-code standards before marking the task complete.

Frequently Asked Questions about clean-code

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

FAQPage Schema
How do I make AI-generated code follow clean code principles?▼

Load coding standards that define concrete rules for naming, function size, and structure. This Skill enforces SRP, DRY, KISS, and YAGNI with specific limits like 20-line functions and maximum 3 arguments.

How to prevent AI edits from breaking other files?▼

Require a dependency check before every edit: identify what imports the file, what it imports, and which tests cover it. The Skill mandates updating the file and all its dependents in the same task.

What coding standards should AI agents follow?▼

Effective standards cover naming conventions, small single-purpose functions, guard clauses over nesting, and no unnecessary comments or abstractions. They should also include a self-check before declaring tasks complete.

Does this Skill work with languages other than TypeScript?▼

Yes, the principles are language-agnostic and apply to PHP, TypeScript, and other languages. The verification script mapping references agents for frontend, backend, mobile, and database work.

When should validation scripts be run after code changes?▼

Each specialist agent runs only its own skill's validation script after completing work, then summarizes errors and warnings to the user. Fixes are applied only after user confirmation, followed by a re-run to verify.