Today I would like to talk about documenting Swift code using the DocC. Documenting your code becomes even more important in the era of modularized apps. Whenever different parts of your app live in multiple Swift Packages, it becomes crucial to provide proper documentation.
A few weeks ago, we discussed Task Groups in Swift, which is an explicit way of executing multiple concurrent tasks and waiting for them to complete. This week, we’ll delve deeper into the topic by exploring the async let syntax in Swift, which offers a convenient way to work with Task Groups implicitly.
Nowadays, Apple platform development has undergone significant changes. Previously, we believed that building the core of an app around UIKit and using SwiftUI for certain screens was a good idea. This week, we’ll delve into the foundation of app development using SwiftUI, while also exploring UIKit for scenarios where performance truly matters.
I decided to continue the topic of Swift Concurrency to cover some not-obvious things. This week we will talk about task yielding and debouncing. Swift concurrency language features provide us with two simple but very powerful functions: yield and sleep. We will try to learn how and when to use them.
Swift Concurrency provides a cooperative cancellation model to handle task cancellation. This week, we will learn what a cooperative cancellation model is, how to use it, and how to be a good citizen and handle it correctly.
Swift Structured Concurrency makes our lives much easier by introducing task groups. Task groups are a way to run a dynamic number of child tasks, await all of them, or cancel. This week, we will learn how to use and optimize task groups in Swift.
The easiest way to size a view in SwiftUI is to place it in a container and allow it to fit its content size. You can also use the frame view modifier to specify a particular concrete size. Anything related to the size of its parent needs hard work using GeometryReader, which is not the easiest way to do things correctly in SwiftUI.
With the latest release of SwiftUI, Apple has introduced a new feature called color mixing. It’s a single function that enables you to perform various creative tasks. In this week’s discussion, we’ll dive into color mixing in SwiftUI and explore its potential adoption.
I’ve been using Swift Concurrency since its initial version, which introduced the async and await keywords to enable asynchronous work. Over time, Swift Concurrency has become more powerful and provides robust data-race safety by allowing the Swift compiler to identify potential issues.
SwiftUI provides the UIViewRepresentable and UIViewControllerRepresentable protocols since its inception. As you might know, we can use them to wrap any UIKit view or controller and place it in the SwiftUI hierarchy.