architecture-patterns

Guide macOS app architecture with Swift 6, SwiftUI, and SOLID principles.

4|Updated Jan 27, 2026
One-click install
npx skills add https://github.com/k97/dock-tile --skill architecture-patterns-k97
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: architecture-patterns
Source: https://github.com/k97/dock-tile/tree/main/.agents/skills/macos-development/architecture-patterns
Command: npx skills add https://github.com/k97/dock-tile --skill architecture-patterns-k97

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the complexity of building scalable, maintainable macOS applications by providing a structured approach to design patterns, SOLID principles, and modular code organization.

Core Features & Use Cases

  • Architectural Guidance: Expert advice on choosing between MVVM, Coordinator, and Repository patterns based on project scale.
  • SOLID Implementation: Practical, Swift-specific refactoring examples for applying SOLID principles to real-world code.
  • Modularization: Strategies for using Swift Package Manager to decouple features and improve build times.
  • Use Case: Use this Skill when refactoring a monolithic ViewModel or deciding how to structure a new multi-window macOS utility.

Quick Start

Ask the architecture patterns skill to review your current project structure and suggest a modularization strategy based on your app size.

Frequently Asked Questions about architecture-patterns

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

FAQPage Schema
How do I structure a macOS app using SwiftUI with modular architecture?

To structure a scalable macOS app with SwiftUI, apply SOLID principles alongside patterns like MVVM or Repository based on project scale. This approach resolves complexity by enforcing modular code organization and separating business logic from views.

What is the best way to refactor a monolithic ViewModel in Swift?

Refactor a monolithic ViewModel by applying SOLID principles and extracting responsibilities into distinct modules using Swift Package Manager. This modularization strategy decouples features, reduces dependencies, and improves testability.

When should I use the Coordinator pattern versus MVVM for a macOS app?

Choose between MVVM and Coordinator patterns based on project scale and complexity. MVVM separates data handling, while Coordinators manage navigation flow, and combining both provides structured navigation and state management.

How does Swift Package Manager help with modularization in macOS applications?

Swift Package Manager enables modularization by decoupling features into isolated packages within macOS applications. This strategy enforces strict architectural boundaries, reduces dependencies, and significantly improves build times.

Can I apply SOLID principles to existing Swift 6 codebases without rewriting everything?

Apply SOLID principles to existing Swift 6 codebases through targeted refactoring rather than complete rewrites. Practical Swift-specific examples guide decoupling features and migrating logic into modular components to ensure maintainability.

Does this architecture guidance support multi-window macOS utility apps?

Yes, this architecture guidance supports multi-window macOS utility apps by recommending patterns like Coordinator and MVVM. These patterns organize complex window navigation and state management for maintainable SwiftUI applications.