Contained in: Building Engaging User Interfaces with SwiftUI
swiftui
iOS & Swift
Building Engaging User Interfaces with SwiftUI
Mar 12 2025 · Multimodal Module (1 hr, 27 mins)
This module explores advanced SwiftUI features and techniques to build complex and visually appealing user interfaces. Students will learn about animation and transitions, building complex layouts, and how to integrate SwiftUI with UIKit to leverage existing code and UI components…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Integrating SwiftUI with UIKit
Mar 12 2025 · Lesson
Learn how to display a UIKit view in SwiftUI by implementing UIViewRepresentable…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
Learn the basics of SwiftUI animations, including the types of animations available…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Integrating SwiftUI with UIKit
Mar 12 2025 · Lesson
Learn how to use a coordinator class to connect UIKit delegates and transfer data to UIKit elements within SwiftUI…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
This lesson introduces SwiftUI animation. Learn how SwiftUI handles much of the tedious work required by earlier frameworks. Then, learn how to set transitions to control how views appear and disappear when the user moves between them…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Integrating SwiftUI with UIKit
Mar 12 2025 · Lesson
…this lesson, you learned how to integrate SwiftUI with existing UIKit views using MapKit. You built views using Representable-derived protocols to integrate SwiftUI with other Apple frameworks, which requires implementing two required methods in these protocols to create the view and do setup work. You created a Coordinator class…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Integrating SwiftUI with UIKit
Mar 12 2025 · Lesson
Learn how to use UIViewRepresentable and coordinator classes to work with UIKit frameworks in SwiftUI projects…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Integrating SwiftUI with UIKit
Mar 12 2025 · Lesson
Learn how to work with UIKit frameworks in your SwiftUI project…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Implementing Complex UI Layouts
Mar 12 2025 · Lesson
Harness the power of SwiftUI’s ViewBuilder to create reusable views…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Implementing Complex UI Layouts
Mar 12 2025 · Lesson
…angle brackets tells Swift that the struct will have a second generic parameter. Instead of specifying an Int, FlightInformation, or another type, you tell SwiftUI to refer to the type as T. There is no type T, but T represents whatever type you pass to the struct upon instantiation…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
Learn about view transitions in SwiftUI…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
Explore animation and view transitions in SwiftUI…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
…direction until it overcomes the initial velocity. Unless you’re a physicist, the animation’s physical model doesn’t intuitively map to the results. SwiftUI introduces a more intuitive way to define a spring animation. The underlying model doesn’t change, but you can specify parameters to the model better…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
Learn to synchronize view transition animations across views as you improve the awards view in an airport app written in SwiftUI…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Implementing Complex UI Layouts
Mar 12 2025 · Lesson
SwiftUI represents an exciting new paradigm for user interface design. SwiftUI relies upon the idea of composing larger views by assembling smaller ones. Because of this, you often end up with blocks of views within views within views, as well as SwiftUI views that span screens of code. Splitting components…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
…that you have an understanding of SwiftUI animations, you’ll apply animation to other places in the app. Open TerminalStoresView.swift in the FlightDetails group. This view displays the stores in each terminal. In this segment, you’ll add some animation to these shapes when they appear. First, add a state…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Implementing Complex UI Layouts
Mar 12 2025 · Lesson
…this lesson, you learned about building complex views in SwiftUI. First, you learned how to use a ViewBuilder to pass views into another view when doing iterations. You also saw how generics let your views work without hard coding specific types. Finally, you saw how using a KeyPath provides…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Implementing Complex UI Layouts
Mar 12 2025 · Lesson
…will go faster than trying to do everything at once. First, you’ll work on the cards. Inside the Timeline folder, create a new SwiftUI view named DepartureTimeView.swift and change the view and preview to: struct DepartureTimeView: View { var flight: FlightInformation var body: some View { VStack { if flight.direction == .arrival { Text…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Mastering SwiftUI Animations
Mar 12 2025 · Lesson
…should now have a basic understanding of animations and transitions in SwiftUI. This lesson focused on creating animations and transitions but not why and when to use them. A good starting point for UI-related questions on Apple platforms is the Human Interface Guidelines, here: https://developer.apple.com/design/human-interface-guidelines/. The WWDC…
iOS & Swift
Lesson in Building Engaging User Interfaces with SwiftUI
Implementing Complex UI Layouts
Mar 12 2025 · Lesson
…graphical representation in the next section. Adding Inline Drawings Now, you’ll add a view to show the flight’s progress. Create a new SwiftUI view named FlightProgressView inside the Timeline group. Change the view to: struct FlightProgressView: View { var flight: FlightInformation var progress: CGFloat var body: some View…