This book explains a range of application architectural patterns and their implementation techniques using a single example app, fully implemented in six architectural patterns.
Instead of advocating for any particular pattern, we lay out the problems all architectures are trying to address: constructing the app’s components, communicating between the view and the model, and handling non-model state. We show high-level solutions to these problems and break them down to the level of implementation for six different architectural patterns — three commonly used and three more experimental.
The common architectures are Model-View-Controller, Online-Only Model-View-Controller, and Model-View-ViewModel + Coordinator. In addition to explaining these patterns conceptually and on the implementation level, we discuss solutions to commonly encountered problems, like massive view controllers.
On the experimental side we explain View-State-Driven Model-View-Controller, ModelAdaptor-ViewBinder, and the Elm architecture. By examining these experimental patterns, we extract valuable lessons that can be applied to other patterns and to existing code bases.
What’ll be in the book
Understand the common problems all patterns are trying to solve.
Learn what common patterns such as MVC, MVVM-C, and Online-Only MVC are all about.
Learn from experimental architectures like View-State-Driven MVC and the Elm architecture.
Understand how each pattern is implemented at the code level.
Understand the commonalities, differences, and trade-offs between architectures.
Take-Aways for Any Code Base
Learn lessons from each architecture that make any code base better.
Techniques to factor out shared code and deal with large view controllers.
The accompanying voice-notes sample app is fully implemented in six architectures.