codebase-design

Solid

Load when a change needs module-boundary, dependency-direction, interface-depth, or architecture simplification decisions; do not use for routine style or formatting rules.

Web & Frontend 84 stars 0 forks Updated 5 days ago

Install

View on GitHub

Quality Score: 78/100

Stars 20%
64
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
0
Description 5%
100

Skill Content

# Codebase Design Use this Skill to improve the shape of code, not to impose generic language style. Prefer the smallest design that makes the current behavior easy to understand, test, replace, and delete. ## Start From Pressure Name the concrete pressure before proposing structure: - which behavior is hard to change or test - which dependency leaks across boundaries - which concept has more than one competing owner - which repeated call pattern proves an interface is missing Do not redesign a module because a textbook pattern could fit. Use `ponytail` to challenge speculative seams and entity growth. ## Seek Deep Modules A deep module offers a small, stable interface while hiding meaningful complexity. Move volatile policy, integration quirks, and invariants behind the narrowest owner that can enforce them. Avoid shallow wrappers that merely rename another call or spread one operation across extra files. Prefer: - one canonical owner for each durable rule - dependencies that point toward stable domain behavior - explicit inputs, outputs, errors, and side effects - public seams that support behavior tests - direct control flow when only one implementation exists ## Prove An Abstraction One adapter means a hypothetical seam; two adapters make it real. Before adding an interface, registry, factory, plugin point, or compatibility layer, show the second concrete use or an unavoidable external boundary. Apply the deletion test: if the new entity disappeared, would req...

Details

Author
JasonxzWen
Repository
JasonxzWen/harness-hub
Created
4 months ago
Last Updated
5 days ago
Language
JavaScript
License
None

Similar Skills

Semantically similar based on skill content — not just same category