4 Comments
User's avatar
Vlad C.'s avatar

Love these kind of articles, cheers!

Jacob Bartlett's avatar

Thanks, Vlad! What could you mean by this? It must be the gifs, right? I'll have even more gifs in my next article.

Vlad C.'s avatar

GIFs first and SwiftUI vs UIKit second of course 😁

Karin Prater's avatar

I have checked the SwiftUI code and can see that its not really ideally written. For example, "ForEach(Array(viewModel.visibleItems.enumerated())" will cause extra work. Changing the closures to use capture lists "onStickerDeleted: { [viewModel] itemID, stickerID in" helps. "VisibleItemReporter" which uses GeometryReader with the y coordiate. I only looked at the code shortly but there is a lot of potential to improve it.

Overall I dont think this is a fair comparison. I am guessing you wrote the code with Claude? The AI code is not as good for SwiftUI vs UIKit, simply because it has more training data for UIKit.

Would love to see the code improved and the performance comparsion more realistic.