Recorded – watch the full episode on YouTube.
Last year was a big year for UIKit with things like those full data sources and compositional collection view layouts. Do you have any wishlist items for UIKit this year?
Janina Kutyn: That's a really good question. I really have not thought about that. I mean, things come up on a daily basis where we're like, “oh, I wish tableview did this or I wish collection view allowed for that. How about multi-column table views?”
Paul Hudson: Ooh, that's got to happen, surely, because of Catalyst. macOS has them everywhere and iOS hasn't. It's quite frustrating.
Janina Kutyn: I would love if something like blur effect had more customization and more also performance-boosting features to them also.
“I would love if something like blur effect had more customization and more also performance-boosting features to them also.”
Paul Hudson: My wishlist for UIKit is always super simple. There are things that we can see being used as standard in so many apps. I want them to be exposed by Apple. Find a way, I don't care how, to make remote image views work. Just make it happen. SDWebImage does it just fine. It's clearly possible to do caching and such inside image view. Make that happen out of the box, please.
All those little half-screen view controllers that are absolutely everywhere. Maps use them. I think Music uses them somewhere. Those little slide-up things with the little pull tab – they're so common. Everyone wants to make those, but they're not built in. I kind of want those things just handed to me here, so I can focus on the more interesting things. For me, remote images or slide-up little view controllers, they're not interesting jobs to solve.
Janina Kutyn: That's true.
Paul Hudson: My app isn't a remote image view app. My app is let's study cross stitching or something like that, not technology. So I want Apple to solve that boring bit, so I can focus on the exciting bit and build fun things with UIKit, ideally.
“If anyone watching has good tips for writing unit tests for view controllers, please send them to me.”
Janina Kutyn: Yeah, that's a good point. Actually, this might be more of my limitation than UIKit's limitation, but I really struggle with writing unit tests for view controllers. So I wonder if maybe there is a way Apple could make that easier. And if anyone watching has good tips for writing unit tests for view controllers, please send them to me.
Paul Hudson: I think the key always is, as soon as you write
import UIKit, you've lost. That's really what it comes down to. Because the UI testing thing is a bit flaky and a bit slow, but you want to get all your model data, all your transformation database, the MVVM effectively, out of the view Ccontroller into a single little struct, so you can test, test, test. Simple inputs, simple outputs, and the view controller is basically a placeholder showing the response data.
This transcript was recorded as part of Swiftly Speaking. You can watch the full original episode on YouTube, or subscribe to the audio version on Apple Podcasts.
SAVE 50% To celebrate Black Friday, all our books and bundles are half price, so you can take your Swift knowledge further without spending big! Get the Swift Power Pack to build your iOS career faster, get the Swift Platform Pack to builds apps for macOS, watchOS, and beyond, or get the Swift Plus Pack to learn advanced design patterns, testing skills, and more.
Link copied to your pasteboard.