Summary
In this chapter, we covered how linking SwiftUI to existing logic and UIKit frameworks can be achieved. First, we looked at how we integrate into a very common approach for networking by using NetworkHelper along with URLSession to perform our network request. From this, we were successfully able to update our SwiftUI View with ease.
Next, we took a deep dive into two of the main representable protocols, UIViewRepresentable and UIViewControllerRepresentable, and stepped through how we previously used these in Chapter 7, Creating a Form with States and Data Binding, in order to implement existing UIKit controls. We covered the differences between using both and understood why we need to take a slightly different approach for UIViewControllerRepresentable ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access