A large iOS application needs to be architected like a house – designed, structured, modularised.
To architect an app, first we need to categorise the modules that can be reused, which implementations can be replaced / updated later. Usually they are:
- Networking module: what will be downloaded from internet. And how to parse them into data models.
- Data models: design the objects.
- Persistence: what will be stored into files, coredata or nsuserdefaults?
- UI: can use storyboard.
- View-Models: mvvm style – instead of using lots of arrays to store data in ur viewcontrolllers – use view model – all the data & states should be kept there! It can be passed around as a whole, or notify/display viewcontrollers when it changes.
There are now 2 popular approaches for iOS Architecture:
- OBJC.IO ARCHITECTURE
- Apple Architecture Guideline
- Apple WWDC Talk