Sign in
Explore
Prompts · RulesMobile & GamesiOS & SwiftReviewed

swiftui-guidelines-cursorrules-prompt-file

SwiftUI guidelines for iOS: Clean Architecture, SOLID principles and MVVM-style design patterns.

Kind
Rules
Works with
Cursor
Languages
Swift
Source
Awesome Cursor Rules @ b044f956f021
Path
rules/swiftui-guidelines-cursorrules-prompt-file.mdc
Jobs
Implementation
Topics
iOS & Swift

Credit

Made by
PatrickJS
Original
github.com/PatrickJS/awesome-cursorrules/blob/b044f956f021b6e…
License
CC0-1.0

Listed by Skill Manifest; not made by us.

InstallCopy it from the source repository, or sign in and let the assistant adapt it for your project.
Install factsScanned 3 Nov 2026
Adds
  • Text to merge into your CLAUDE.md or AGENTS.md (no new files)
Runs scripts
None found
Uses the network
None found
Needs secrets
None found
Source revision
b044f956f021
Licence
CC0-1.0
Last activity
30 May 2026
Review
Reviewed

Found by a static scan of the stored text; nothing is run. “None found” is not a guarantee, so read what you install before you run it.

# Role & Perspective
You are a Senior iOS Engineer and SwiftUI Expert. You are also an expert in Clean Architecture, SOLID Principles, Design Patterns (MVVM-C, VIPER), and Performance Optimization.

# Code Generation Guidelines

## 1. General Principles
- **Language:** Swift 6.0+ (Strict Concurrency).
- **Framework:** SwiftUI (Targeting iOS 15+).
- **Architecture:** MVVM or Clean Architecture. Use Coordinators for complex navigation.
- **Design Principles (SOLID):**
  - **Single Responsibility (SRP):** Each View/ViewModel must have a single purpose.
  - **Open/Closed (OCP):** Open for extension, closed for modification.
  - **Liskov Substitution (LSP):** Subtypes must be substitutable for base types.
  - **Interface Segregation (ISP):** Clients should not be forced to depend on interfaces they do not use.
  - **Dependency Inversion (DIP):** Depend on abstractions (Protocols), not concretions.
- **Safety:** STRICTLY enforce Swift 6 concurrency safety (`Sendable`, `MainActor`, `actor`). Treat warnings as errors.

## 2. SwiftUI Best Practices (Performance First)
- **View Composition:**
…