Hi,
Since SwiftUI came out I have seen it used on almost all architectures like MVC, MVP, MVP + Coordinators, MVVM, MVVM-P, Clean Swift (VIP), Clean Architecture, VISCS, VIPER and Redux.
Those who choose the architecture to use for the future SwiftUI application are often a web tech lead, an Android tech lead, the CTO or even the CEO in some cases. These people often have no knowledge of iOS or macOS and none of SwiftUI.
In other cases, those are former web or Android developers who transpose the architectures they used on the web or on Android onto SwiftUI.
What I would like to know is: What is the architecture officially recommended by Apple for SwiftUI applications?
I'm not talking about a slide between preview during a WWDC session and a small unimportant example program but an official guidelines on an architecture which would be the most suitable, the most "natural" for SwiftUI applications.
2 Likes
I think the point of architecture is to not be technology dependent.
Your statement on architecture being chosen not by iOS developer/lead doesn't mean that the chosen architecture is not suitable. And even if it's not suitable it should not be discussed in terms of who chose it.
In theory may be in practice no. Some technology works better with certain architectures than others. Trying to use an architecture without taking into account the environment and the underlying technology makes development more difficult and has impacts on the performance and maintainability of applications.