mcpField
S
solid-principles

solid-principles

github.com/gkwaDevelopment035 installsUpdated today
Repository

About solid-principles

solid-principles is a coding skill that applies the five SOLID principles and information hiding to code organization. It also encourages focused modules and treats keeping files under 200 lines as a goal rather than a strict rule.

Key features

  1. 01Apply the five SOLID principles
  2. 02Improve information hiding
  3. 03Organize logic into focused modules
  4. 04Treat 200 lines as a file-size goal

Use cases

  1. 01Reviewing class responsibilities and dependencies
  2. 02Breaking extensive logic into smaller files
  3. 03Assessing interfaces and module boundaries

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/gkwa/volcanicviper --skill solid-principles

After installing, type/solid-principlesin Claude Code to confirm it loaded.

Bundled filestile.json

Details

From the project README

Follow SOLID design principles and maintain good information hiding:

  1. Single Responsibility Principle (SRP): A class should have only one reason to change.
  2. Open-Closed Principle (OCP): Open for extension, closed for modification.
  3. Liskov Substitution Principle (LSP): Subclass objects should be substitutable for superclass objects.
  4. Interface Segregation Principle (ISP): Many client-specific interfaces are better than one general-purpose interface.
  5. Dependency Inversion Principle (DIP): High-level modules should not depend on low-level modules — both should depend on abstractions.

Individual code files should strive to stay under 200 lines. This is a goal, not a strict limit — justified outliers are fine.

Decompose extensive logic into multiple discrete files rather than accumulating lines in a single file. This promotes information hiding and keeps modules focused and comprehensible.

When writing code, consider:

  • Does it adhere to SOLID principles? If not, which principles are being violated?
  • Is the code organized into small, focused units?
  • Are there areas where information hiding could be improved?

Comments

Markdown supported