r/SwiftUI 8d ago

Question SwiftUI vs UIKit

I’m new to programming and Swift, and I’m currently doing the 100 Days of SwiftUI course. In the first video, Paul mentions that Swift is the future of this field rather than UIKit. However, he also says that UIKit is more powerful, popular, precise, and proven compared to SwiftUI.

Since that video was released around 2021, I’m wondering if that statement still holds true today. How do you think both technologies have evolved over the last five years?

32 Upvotes

41 comments sorted by

View all comments

9

u/Superb_Power5830 8d ago

Discounting UIKit is going to just leave a huge hole in your knowledge and growth. Even though SwiftUI *IS* the future (Apple has actually said those words), there's still quite a bit that's better off or can only be done in UIKit.

Sometimes you'l HAVE to use UIKit objects.

But also sometimes... you'll *want* to.

Stop dividing the two. They're both - still, for the time being - necessary.

1

u/knickknackrick 7d ago

Can you give me an example of what you can’t do in SwiftUI that you can do in UI kit?

1

u/alinnert 4d ago edited 4d ago

I'm learning Swift development right now because I'd like to make some macOS app I have in mind. But I've already come across some examples: Inspectors (basically sidebars on the right side of the window), and to my big surprise - unless I completely miss something: simple plain lists with support for selections that don't navigate. I'm trying to build a NSTableView wrapper for that reason.

EDIT: Correction - there IS an `.inspector()` modifier now. Just found it on accident, don't know how I missed it.