clean-architecture
Structure software around the Dependency Rule: source code dependencies point inward from frameworks to use cases to entities. Use when the user mentions "architecture layers", "dependency rule", "ports and adapters (hexagonal)", "onion architecture", "screaming architecture", "where should business logic go", "decouple from the database", "swap the framework without a rewrite", or "keep business rules independent". Also trigger when deciding which layer code belongs in, isolating core logic from infrastructure, defining module boundaries, or debating whether the framework should call your code or the reverse. Covers component principles, boundaries, and SOLID. For code-level quality, see clean-code. For domain modeling, see domain-driven-design.
适合你,如果正在设计或重构分层架构,想让业务逻辑独立于框架和数据库
npx oh-my-skill add wondelai/skills/clean-architecturecurl -fsSL https://oh-my-skill.com/install.sh | bash -s -- wondelai/skills/clean-architecturenpx oh-my-skill verify wondelai/skills/clean-architecture怎么用
商店整理自技能原文 · 版本 326b380 · 表述以原文为准Claude 会帮你按照依赖规则组织软件架构,确保业务逻辑独立于框架、数据库等外部细节。它会分析你的代码分层,指出依赖方向是否正确,并给出修复建议。
当你提到“架构分层”、“依赖规则”、“六边形架构”等关键词,或询问业务逻辑该放哪、如何解耦数据库时触发。