Skip to main content
SwiftAI Boilerplate Pro ships with configurations for Claude-powered iOS development across Claude Code, Xcode Coding Intelligence, Cursor AI, and Bolt AI. Each setup points the assistant at the same project architecture so generated code fits the boilerplate instead of guessing. No setup required. Open the project and start building.
Building a separate app from this template? The App Generator is a standalone macOS product (coming soon) that drives your own coding-agent CLI to scaffold a differentiated, App Store Guideline 4.3-safe app from the boilerplate. See Pricing & License for details and the waitlist.

For most SwiftAI Boilerplate Pro projects, start here:
1

Open the repository root

Open the folder that contains AGENTS.md, SwiftAIBoilerplatePro.xcodeproj, Packages/, and docs/. The root AGENTS.md is the shared entry point that points every agent at docs/CLAUDE.md and docs/INDEX.md.
2

Use Xcode Coding Intelligence for build-aware work

Xcode Coding Intelligence with Claude Agent is a strong fit for Swift apps because it can stay close to Xcode’s project, build, simulator, and diagnostics workflow.
3

Use Claude Code for larger agentic changes

Claude Code is best when you want the agent to inspect many files, implement a full feature, run commands, and iterate until the project builds.
4

Use Cursor for focused editing

Cursor is useful for inline edits, local refactors, and reviewing generated code while you are already working in the editor.
If Claude says it does not see the project instructions, ask it to summarize docs/CLAUDE.md. If it cannot, restart the agent from the repository root rather than from a subdirectory or a single file.

Tool Comparison

ToolBest ForProject Context
Xcode Coding IntelligenceSwift app work inside Xcode, build issues, simulator-aware iterationReads root AGENTS.mddocs/CLAUDE.md when started from the project root
Claude CodeLarger autonomous coding tasks and verification loopsReads root AGENTS.md, which points to docs/CLAUDE.md
Cursor AIInline edits, refactors, and code review while editingReads .cursor/rules/*.mdc (plus AGENTS.md)
Bolt AI chat modesSpecialized chat personas and prompt-driven workflowsUses .bolt/chat-modes.json and project files you provide as context

Claude Code and Claude Agent (CLAUDE.md)

The boilerplate includes a production-tested docs/CLAUDE.md that gives Claude Code full project context. A root AGENTS.md is the shared entry point all agents read first; it points Claude Code, Cursor, Codex, and others at docs/CLAUDE.md and docs/INDEX.md, so generated code fits the boilerplate from the first message.

What CLAUDE.md Covers

  • Architecture: MVVM patterns, module boundaries, which abstractions to use
  • Build commands: Environment-aware instructions for Xcode MCP vs Claude Code CLI
  • Anti-patterns: No UIKit, no ObservableObject, no raw URLSession
  • File conventions: Naming patterns, organization, where new code belongs
  • Integration specifics: Supabase, RevenueCat, OpenRouter configuration

How Agentic Development Works

  1. Open Claude Code in your project directory
  2. Describe the feature you want
  3. Claude reads your codebase, generates code following your patterns, builds it, and iterates until it works
Claude understands the module boundaries, uses the right abstractions, and writes code that looks like the rest of your project.

Example Workflow

You: "Add a favorites feature. Users should be able to bookmark conversations
     and see them in a dedicated tab."

Claude Code:
  - Reads AGENTS.md / docs/CLAUDE.md and the existing module structure
  - Creates SwiftData model in Storage package
  - Adds FavoritesRepository with protocol
  - Builds FavoritesViewModel (@Observable) following MVVM pattern
  - Creates FavoritesView using DesignSystem tokens
  - Wires dependencies through CompositionRoot
  - Runs build to verify compilation

Community Skills

You can extend Claude’s iOS knowledge with community skills. These teach Claude about platform conventions, Xcode tooling, and SwiftUI best practices.

Apple Platform Skills

Apple platform conventions, Xcode project structure, SwiftUI, and App Store review awareness.
git clone https://github.com/rshankras/claude-code-apple-skills.git
mkdir -p .claude/skills
cp -R claude-code-apple-skills/skills/* .claude/skills/
Source: rshankras/claude-code-apple-skills

iOS Simulator

Lets Claude boot, build, install, and interact with the iOS Simulator directly.
/plugin marketplace add conorluddy/ios-simulator-skill
/plugin install ios-simulator-skill@conorluddy
Source: conorluddy/ios-simulator-skill
Run /plugin ... commands inside Claude Code or Claude Agent chat. Run git, cp, and npx commands in your terminal. For the full list of recommended skills and module mappings, see the Agentic Development Setup guide.

Cursor AI Rules (.cursor/rules/)

Cursor AI reads .mdc (Markdown Code) files from your project to understand patterns and constraints. Six rule files are included.

Included Rule Files

core.mdc

Applied to: All Swift filesFile size limits (max 400 lines), MVVM patterns, dependency injection, error handling, Swift Concurrency, testing requirements.

swiftui-views.mdc

Applied to: View files (*View.swift)View composition, state management, list optimization, navigation, form handling, accessibility.

architecture.mdc

Applied to: Repositories, Clients, PackagesModular package boundaries, protocol-based APIs, repository pattern, CompositionRoot, structured logging, test doubles.

design-system.mdc

Applied to: DesignSystem, AppShellDSColors tokens, DSTypography type scale, DSSpacing tokens, component library usage, theme consistency.

app-store-differentiation.mdc

Applied to: Swift, config, and Markdown filesGuideline 4.3(a) differentiation (binary, metadata, concept), the APP_STORE_4_3_HARDENING.md checklist, and the FeatureChat to AI coupling when removing chat.

ios-platform-safety.mdc

Applied to: Swift, Info.plist, PrivacyInfo.xcprivacyPublic APIs only, Swift 6 concurrency, permission strings and privacy manifests, StoreKit/IAP for digital goods, accessibility baselines, and secrets via the existing HTTPClient + xcconfig.

How It Works

Open the project in Cursor. The rules load automatically. Ask Cursor to build something, and it follows your architecture.
You: "Create a new chat settings view"

Cursor generates code with:
  - DSColors, DSTypography, DSSpacing (DesignSystem tokens)   ✅
  - Protocol-based dependencies (testable)                    ✅
  - Under 400 lines (properly composed)                       ✅
  - Loading and error states                                  ✅
  - Accessibility labels                                       ✅

Example Prompts

"Create a new settings view using DesignSystem components"
"Add a profile page with avatar, name, email, and sign-out"
"Build a subscription paywall with three tiers"
Cursor will use DSColors for colors, DSTypography for type, DSSpacing for layout, and create a proper @Observable ViewModel with loading and error states.
"Add a ProfileViewModel with user info and sign-out"
"Create SettingsViewModel with theme switching"
"Build ChatViewModel with message streaming"
Cursor will mark ViewModels as @MainActor @Observable, inject dependencies via initializer, use protocol types, and add structured logging.
"Create a new feature package for Notifications"
"Add a feature package for User Profile"
Cursor will create proper Package.swift, define protocol-based public APIs, keep implementation internal, and add tests.
"Refactor this to use repository pattern"
"Extract this logic to a separate package"
"Convert this to use DesignSystem components"

Bolt AI Chat Modes (.bolt/)

Bolt AI provides 12 specialized AI assistants for different development tasks. Each mode loads relevant context and uses a domain-specific system prompt.

Available Chat Modes

iOS Developer

/dev (default). General iOS/SwiftUI development with MVVM and async/await.

Architecture Advisor

/arch. Package boundaries, protocol-based APIs, clean architecture.

SwiftUI

/ui. View composition, DesignSystem usage, state management, accessibility.

Feature Dev

/feature. Self-contained feature modules with protocol APIs and tests.

Integration

/integration. Supabase, RevenueCat, Firebase setup and troubleshooting.

Testing

/test. Unit tests, mock protocols, test doubles, async testing.

Debug

/debug. Bug diagnosis, crash analysis, memory leaks, performance.

Performance

/perf. Memory management, lazy loading, rendering optimization.

Package Dev

/package. Swift Package Manager, API design, dependencies.

Deploy

/deploy. App Store submission, TestFlight, provisioning, CI/CD.

Accessibility

/a11y. VoiceOver, Dynamic Type, inclusive design, WCAG compliance.

Documentation

/doc. Technical writing, API docs, integration guides.

Before and After

Without configurations, AI generates code with hardcoded colors, no ViewModel, direct singleton dependencies, and no error handling. With configurations, the same prompt produces code that follows your architecture.

Without Configurations

Prompt: “Create a user profile view with avatar and sign-out”
struct ProfileView: View {
  @State var user: User?

  var body: some View {
    VStack {
      Image(systemName: "person.circle")
        .font(.system(size: 80))
        .foregroundColor(.blue)  // ❌ Hardcoded color

      Text(user?.name ?? "")
        .font(.title)  // ❌ Not from DesignSystem

      Button("Sign Out") {  // ❌ No error handling
        AuthManager.shared.signOut()  // ❌ Direct dependency
      }
      .padding()
      .background(Color.red)  // ❌ Hardcoded color
    }
  }
}

With Configurations

Same prompt, same AI tool:
import SwiftUI
import DesignSystem
import Auth
import Core

struct ProfileView: View {
  @State private var viewModel: ProfileViewModel

  var body: some View {
    ScrollView {
      VStack(spacing: DSSpacing.lg) {
        Circle()
          .fill(DSColors.primary)
          .frame(width: 80, height: 80)
          .overlay {
            Text(viewModel.user?.name?.prefix(1).uppercased() ?? "")
              .font(DSTypography.titleL)
              .foregroundStyle(.white)
          }

        VStack(spacing: DSSpacing.sm) {
          Text(viewModel.user?.name ?? "Loading...")
            .font(DSTypography.titleM)

          if let email = viewModel.user?.email {
            Text(email)
              .font(DSTypography.body)
              .foregroundStyle(DSColors.textSecondary)
          }
        }

        SAIButton("Sign Out", style: .secondary, layout: .block) {
          Task { await viewModel.signOut() }
        }
        .padding(.top, DSSpacing.lg)
      }
      .padding(DSSpacing.lg)
    }
    .navigationTitle("Profile")
    .alert("Error", isPresented: Binding(
      get: { viewModel.errorMessage != nil },
      set: { if !$0 { viewModel.errorMessage = nil } }
    )) {
      Button("OK") { viewModel.errorMessage = nil }
    } message: {
      Text(viewModel.errorMessage ?? "")
    }
    .task { await viewModel.load() }
  }
}

@MainActor
@Observable
final class ProfileViewModel {
  var user: AuthUser?
  var isLoading = false
  var errorMessage: String?

  private let authClient: any AuthClient

  init(authClient: any AuthClient) {
    self.authClient = authClient
  }

  func load() async {
    isLoading = true
    defer { isLoading = false }
    user = await authClient.currentUser()
  }

  func signOut() async {
    isLoading = true
    errorMessage = nil
    defer { isLoading = false }

    do {
      try await authClient.signOut()
      AppLogger.info("User signed out", category: AppLogger.auth)
    } catch {
      errorMessage = AppError.from(error).localizedUserMessage
      AppLogger.error("Sign out failed: \(error)", category: AppLogger.auth)
    }
  }
}
DesignSystem tokens, protocol-based dependencies, proper MVVM with @Observable, localized error handling, loading state, structured logging, @MainActor, async/await. All from the same one-line prompt.

Customization

Modifying Cursor Rules

Edit .mdc files in .cursor/rules/. Each file has YAML frontmatter (description, globs, alwaysApply) followed by markdown sections with good/bad code examples. Changes take effect when you save.

Modifying CLAUDE.md

Edit docs/CLAUDE.md (or the root AGENTS.md entry point). Add your own patterns, anti-patterns, or module-specific instructions. Claude picks up changes on the next conversation.

Adding Bolt Chat Modes

Edit .bolt/chat-modes.json to add custom modes:
{
  "chatModes": {
    "my-mode": {
      "name": "My Mode",
      "description": "What this mode does",
      "systemPrompt": "Instructions for AI",
      "context": ["paths/to/focus/on"],
      "tools": ["codeGeneration", "fileManagement"]
    }
  }
}

Documentation

Agentic Development Setup

CLAUDE.md details and community skills

Cursor Rules README

Detailed guide on Cursor AI rules

Architecture Guide

The patterns AI follows

DesignSystem Guide

Design tokens reference

Questions

None of them are required. All are supported. Xcode Coding Intelligence is a great default for Swift work inside Xcode. Claude Code works best for agentic development, such as building full features from a description. Cursor works best for inline code generation while you edit. Bolt works best for chat-based task switching. Use whichever fits your workflow, or combine them.
Yes. The root AGENTS.md is read by most coding agents, and the patterns in docs/CLAUDE.md and the .mdc files work as reference for any AI tool. You can paste relevant sections into ChatGPT, Copilot, or any assistant that accepts context.
The opposite. AI configurations make code generation faster and more accurate because the AI gets it right the first time. Less time fixing, more time shipping.
Yes. Edit docs/CLAUDE.md (or root AGENTS.md), .cursor/rules/*.mdc, or .bolt/chat-modes.json to match your preferences. Changes take effect immediately (Cursor, Bolt) or on the next conversation (Claude Code).
No. These configurations only guide AI code generation. They don’t lint or enforce anything on code you write by hand.

Next Steps

Build Your First Feature

Use AI to build a feature with your project’s patterns

Architecture Overview

Understand the patterns AI follows

Testing Guide

Let AI write tests for your features