Swiftui Mvvm

Use this skill when working with SwiftUI ViewModels — creating, refactoring, or testing them. Triggers for: setting up a ViewModel for a SwiftUI screen, extracting logic from a View into a ViewModel, migrating from ObservableObject to @Observable, modeling async state (instead of separate Bool flags like isLoading/hasError), injecting dependencies into ViewModels, writing unit tests for @Observable ViewModels, NavigationStack/Router setup, or any question about SwiftUI app architecture. Also use when a SwiftUI View imports too much business logic, when someone asks how to structure a SwiftUI screen 'the modern way,' or when they ask about @State/@Bindable ownership, ViewState patterns, or why their ViewModel shouldn't import SwiftUI.

rusel95 5f8e1f0 12 files · 89.6 KB Updated

File contents

rusel95/ios-agent-skills/tree/main/skills/swiftui-mvvm commit 5f8e1f0843

Frequently asked questions

npx skillmds@latest add rusel95/swiftui-mvvm