Using Diffable Data Source with Collection Views
If you have some experience with iOS app development, you should be very familiar with the data source protocols such as UICollectionViewDataSource and UITableViewDataSource. Traditionally, to populate data in a collection view,...
SwiftUI Tab View: Building a Paged Scrolling View with PagedTabViewStyle
In the earlier tutorial, we showed you how to work with TabView to display a tab bar interface. In iOS 14, Apple introduced a new style called PageTabViewStyle in the SwiftUI framework for developers to create paged scrolling...
How to Draw Lines and Create Pie Charts Using SwiftUI
For experienced developers, you probably have used the Core Graphics APIs to draw shapes and objects. It’s a very powerful framework for you to create vector-based drawings. SwiftUI also provides several vector drawing APIs...
Introducing SwiftUI TabView and Working with Tab Bar Customization
The tab bar interface appears in some of the most popular mobile apps such as Facebook, Instagram, and Twitter. A tab bar appears at the bottom of an app screen and let users quickly switch between different functions of an app....
Announcing Mastering SwiftUI Book for Xcode 12 and iOS 14
We are launching the update of our Mastering SwiftUI book for Xcode 12 and iOS 14. Along with the release of Xcode 12, Apple released a big update to the SwiftUI framework with a lot of additions. Other than adding new UI...
Using matchedGeometryEffect to Create View Animations in iOS 14
In iOS 14, Apple introduced a lot of new additions to the SwiftUI framework like LazyVGrid and LazyHGrid. But matchedGeometryEffect is the new one that really caught my attention because it allows developers to create some...
How to Customize the Appearance of SwiftUI Toggle
Earlier, we wrote a tutorial on customizing the appearance of a SwiftUI button. This week, let’s see how to customize the look & feel of a SwiftUI toggle. If you’ve read the tutorial, you know we can use a...
SwiftUI Animation Basics: Building a Loading Indicator
Have you ever used the magic move animation in Keynote? With magic move, you can easily create slick animation between slides. Keynote automatically analyzes the objects between slides and renders the animations automatically. To...
Using SwiftUI TextEditor for Multiline Text Input
The first version of SwiftUI doesn’t come with a native UI component for multiline text field. For multiline input, you can wrap a UITextView from the UIKit framework and make it available to your SwiftUI project by...
Building an Expandable List View with Inset Grouped Style Using SwiftUI
SwiftUI list is very similar to UITableView in UIKit. In the first release of SwiftUI, Apple’s engineers already made creating list view construction a breeze. You do not need to create a prototype cell and there is no...