Skip to content
Tutorials Center
My learning

Topics

iOS and SwiftUI Tutorial

Learn iOS and SwiftUI step by step: 46 lessons in 10 chapters with examples, quizzes, diagrams and projects.

Start learning →

of lessons completed

Getting Started

  1. 1 The iOS Platform and Ecosystem What iOS, iPadOS, SwiftUI and UIKit are, how Apple's platforms fit together, how the App Store works, and how this course teaches iOS without a simulator.
  2. 2 Xcode and Your First SwiftUI App Install Xcode, create a SwiftUI project, understand its files, use previews and the simulator, and learn what Info.plist and the asset catalog do.
  3. 3 The SwiftUI Mental Model Understand declarative UI: a view is a function of state, body returns a view tree, structs make views cheap, and identity lets SwiftUI update only what changed.
  4. 4 Swift Features SwiftUI Relies On The Swift features behind SwiftUI code: structs, closures and trailing closure syntax, opaque some View, property wrappers and result builders, with a runnable builder.

Views and Layout

  1. 5 Text, Images and SF Symbols Show text and pictures in SwiftUI: Text styling and formatting, Label, SF Symbols, asset catalog images, resizable images and AsyncImage for remote photos.
  2. 6 View Modifiers and Their Order Learn how SwiftUI modifiers wrap views, why padding, background and frame give different results in different orders, and how to write a custom ViewModifier.
  3. 7 VStack, HStack, ZStack and Spacer Arrange SwiftUI views with VStack, HStack and ZStack. Learn alignment, spacing, Spacer, Divider and layout priority, plus a runnable model of how a row shares its width.
  4. 8 How SwiftUI Layout Works Understand SwiftUI layout as a three-step negotiation: the parent proposes a size, the child chooses its own, the parent places it. Covers frame, fixedSize, GeometryReader and ViewThatFits.
  5. 9 List, ForEach and Identifiable Show collections in SwiftUI with List and ForEach. Learn Identifiable and stable ids, sections, swipe actions, pull to refresh and when to use LazyVStack and LazyVGrid.
  6. 10 Buttons, Toggles, Sliders and Pickers Learn the core SwiftUI controls: Button, Toggle, Slider, Stepper, Picker, DatePicker, Menu and ControlGroup, with button roles, styles and accessibility basics.

State and Data Flow

  1. 11 @State and @Binding Learn how @State owns a value in a SwiftUI view, how the $ prefix makes a Binding, and how child views edit their parent's data without owning it. Includes a runnable Binding model.
  2. 12 @Observable and Observation Share model data across SwiftUI views with the @Observable macro. Learn @State ownership, @Bindable, @Environment, when views re-render, and how to migrate from ObservableObject.
  3. 13 Choosing the Right Property Wrapper A decision guide for @State, @Binding, @Bindable, @Environment, @AppStorage and @SceneStorage, with the single-source-of-truth rule and the mistakes to avoid.
  4. 14 The Environment and Dependency Injection Learn how SwiftUI's environment passes values down the view tree, how to add custom keys and observable models, and how to inject fake services for previews and tests.
  5. 15 View Identity and Lifecycle Understand structural and explicit identity in SwiftUI, why @State resets, and how onAppear, task, onChange and id() behave, with runnable stand-ins.
  6. 16 Common SwiftUI Pitfalls Learn the SwiftUI bugs that bite most often: state changes in body, the wrong property wrapper, heavy body code, AnyView, unstable ids and retain cycles.

Navigation and App Structure

  1. 17 NavigationStack and Navigation Paths Learn SwiftUI NavigationStack: value-based NavigationLink, navigationDestination, path bindings and programmatic navigation, with a runnable path-stack model.
  2. 18 Tab Views, Sheets, Alerts and Popovers Learn SwiftUI TabView and every kind of presentation: sheet, full-screen cover, alert, confirmation dialog and popover, driven by state, with detents and dismiss.
  3. 19 NavigationSplitView and iPad Layouts Build sidebar-and-detail apps with NavigationSplitView, adapt layouts to size classes and Dynamic Type, and learn how multi-window works on iPad.
  4. 20 The App Protocol, Scenes and Scene Phase Learn how a SwiftUI app starts with @main and the App protocol, how WindowGroup scenes work, and how to react to scenePhase and the app delegate.
  5. 21 Deep Links and Universal Links Open your iOS app from a URL: custom schemes, universal links, onOpenURL, and a safe router that turns a URL into a NavigationStack path.

Data, Networking and Persistence

  1. 22 Codable and JSON in iOS Apps Decode JSON into Swift models with Decodable: CodingKeys, snake_case, dates, optional fields, nested data and readable decoding errors, with runnable examples.
  2. 23 Networking with URLSession and async/await Fetch data in a SwiftUI app with URLSession and async/await: status codes, typed errors, an idle/loading/loaded/failed state enum, cancellation and App Transport Security.
  3. 24 MVVM and App Architecture in SwiftUI Organize a SwiftUI app with view models, @MainActor, repositories and protocols, keep logic out of views, and learn when MVVM is more structure than you need.
  4. 25 UserDefaults, @AppStorage and Files Save small settings with UserDefaults and @AppStorage, and larger data as Codable files in the app sandbox. Learn which folder to use and how to load safely.
  5. 26 SwiftData Basics Store app data with SwiftData: define models with @Model, set up a ModelContainer, fetch with @Query, insert and delete, add relationships and filter with predicates.
  6. 27 Core Data, CloudKit and Sync Know when Core Data still matters, how NSPersistentCloudKitContainer mirrors data to iCloud, what the key-value store is for, and how to design for sync conflicts.
  7. 28 Keychain, Biometrics and App Security Store passwords and tokens in the Keychain, add Face ID or Touch ID with LocalAuthentication, and avoid common security mistakes: embedded secrets, ATS and privacy manifests.

Concurrency and Performance

  1. 29 Concurrency in iOS: MainActor, Tasks and Async Work Keep your iOS app responsive: the main thread rule, @MainActor, Task and the .task modifier, structured concurrency, Sendable and Swift 6 strict concurrency.
  2. 30 Performance, Instruments and Smooth Scrolling Find and fix slow SwiftUI screens: keep body cheap, use lazy containers, downsample images, read hitches in Instruments and track down memory leaks.

Polish and Platform Features

  1. 31 Animations and Transitions Learn SwiftUI animation: withAnimation, the animation(_:value:) modifier, springs, transitions, matchedGeometryEffect, phase and keyframe animators, and animatable data.
  2. 32 Gestures, Shapes, Canvas and Charts Learn SwiftUI gestures (tap, drag, long press, GestureState), custom Shape and Path drawing, Canvas for fast graphics, and Swift Charts basics with runnable stand-ins.
  3. 33 Accessibility and Localization Make SwiftUI apps usable by everyone and ready for every language: VoiceOver labels, Dynamic Type, contrast, reduce motion, String Catalogs, plurals and right-to-left layouts.
  4. 34 Notifications, Widgets and App Intents Understand iOS local and push notifications, WidgetKit timelines, App Intents for Siri and Shortcuts, and Live Activities, with runnable stand-ins for triggers and timelines.
  5. 35 UIKit Interoperability Mix SwiftUI and UIKit in one app: wrap UIKit views with UIViewRepresentable, use coordinators for delegates, embed SwiftUI with UIHostingController, and know when to use each.

Testing and Shipping

  1. 36 Testing View Models and UI Learn to test iOS and SwiftUI apps: Swift Testing for logic, XCTest basics, UI tests with XCUIApplication, preview-driven development, async tests and fakes, with a test harness stand-in.
  2. 37 Debugging Xcode Apps Debug iOS and SwiftUI apps in Xcode: breakpoints, lldb, print and Logger, the view debugger, crash logs, symbolication and the runtime errors you will meet most.
  3. 38 Signing, TestFlight and App Store Release Ship an iOS app: certificates, provisioning profiles, bundle IDs, capabilities, TestFlight testing, App Review guidelines, privacy labels and version and build numbers.

Projects

  1. 39 Project: A To-Do App Build a SwiftUI to-do app step by step: model, list, add, complete and delete, state design and saving to disk with Codable. The logic runs here; the UI is shown read-only.
  2. 40 Project: A Weather App with Networking Build a SwiftUI weather app: decode a forecast, model load states, search cities, write a view model and handle error and empty states. Runs against a fake API here.
  3. 41 Project: A Notes App with SwiftData Build a notes app with SwiftData: model design, @Query sorting and search, pinned notes, a detail screen with navigation and deletion. Includes a runnable model stand-in.
  4. 42 Project: A Habit Tracker Build a habit tracker in SwiftUI: model check-ins, compute current and best streaks with calendar math, schedule reminders and chart the week. The streak engine runs here.
  5. 43 Project: An Expense Tracker Design an expense tracker for iOS: money as integer cents, currency formatting, grouping by month, filters, Swift Charts and CSV export, with runnable logic.

Practice and Interview

  1. 44 Practice: SwiftUI Exercises Twelve SwiftUI exercises on state, bindings, layout, navigation and data flow, each with a runnable stand-in check and a solution in real SwiftUI code.
  2. 45 iOS and SwiftUI Interview Questions Prepare for an iOS interview: state vs binding, ARC and retain cycles, view identity, concurrency, architecture and UIKit lifecycle, with clear model answers.
  3. 46 iOS and SwiftUI Cheat Sheet A one-page SwiftUI quick reference: property wrapper chooser, layout and modifier cheat sheet, navigation and presentation snippets, Xcode shortcuts and commands.