Architecture
Links
- 2021.10 iOS Architecture at Lyft High level overview of their architecture - there’s also a podcast
- 2020.05 Understanding Creational Design Patterns
- 2020.04 RIBs is Uber’s cross-platform architecture framework. This framework is designed for large mobile applications that contain many nested states.
- 2020.04 Design Patterns implemented in Swift 5.0
- 2017.11 View-state driven applications
- 2017.10 iOS Architecture: A State Container based approach (2 parts)
- 2017.09 Highly maintainable app architecture
- 2017.09 Managing different environments in your Swift project with ease
- 2017.08 Design Patterns on iOS using Swift
- 2017.03 IB Free in Practice 1: Managing a Modal
- 2016.06 SOLID Principles in Swift
- 2015.11 iOS Architecture Patterns Demystifying MVC, MVP, MVVM and VIPER
Sample Code
- 2020.10 ⭐️ iOS-Clean-Architecture-MVVM
- 2020.05 CleanArchitectureRxSwift
Refactoring
- 2018.08 Refactoring Massive App Delegate using 3 different patterns: Command, Composite and Mediator
- 2017.10 Avoiding singletons in Swift
- 2017.08 Replacing legacy code using Swift protocols
- 2017.03 The Recipe for Singletons Removal
Lighter view controllers
- Protocol-oriented, type-safe data source objects that keep your view controllers light (with video)
- Avoiding Massive View Controllers by refactoring
Dependency Injection
- 2021.12 Lightweight dependency injection and unit testing using async functions What if we could actually make our code fully testable in a way that doesn’t require us to introduce any new protocols, mocking types, or complicated abstractions? Let’s explore how we could make use of Swift’s new
async/await
capabilities to make that happen. - 2021.07 Resolver for iOS Dependency Injection: Getting Started
- 2020.04 Dependency Injection via Property Wrappers
- 2019.12 Practical Dependency Inversion in Swift
- 2019.07 Better Storyboards with Xcode 11 explains how to use
@IBSegueAction
to support DI using Storyboards - 2018.11 Dependency Injection on iOS (4 parts)
- 2016.11 SwinjectMVVMExample An example to use Swinject in MVVM architecture with ReactiveCococa
- 2015.11 Dependency Injection Framework for Swift - Introduction to Swinject. Very nice intro to DI.
Modular Design
- 2020.07 Modern Modular Apps With Xcode 12 and Swift Package Manager (and also Modern modular apps with Xcode 11 and Swift Package Manager)
- 2019.12 Modular iOS Architecture @ Just Eat
- 2019.12 Breaking an app up into modules
- 2019.08 Modular Architecture in iOS Interesting aproach of using CocoaPods for maintaining internal and external modules
- 2018.05 Modular iOS. Part 1: Strangling the Monolith, Part 2: Splitting A Workspace into Modules, Part 3: Configuration & Testing of Modules, Part 4: Sharing Configuration Between Modules
MVC
Apple’s MVC is not the same with traditional MVC, the main difference being that Apple does not allow the direct connection between view and model (this is assigned to the controller instead, which acts as the mediator). Whenever a cell updates itself using a model reference, the MVC pattern breaks (since this communication should have been done by the controller).
- 2019.04 Model-View-Controller (MVC) in iOS: A Modern Approach
- 2017.11 A Better MVC (5 parts)
- 2017.10 The worst possible application
- 2017.05 #41 Architecture Wars – MVC strikes back & takes a photo with AVFoundation
- 2017.02 Looking at Model-View-Controller in Cocoa
MVVM
- 2020.04 Modern MVVM iOS App Architecture with Combine and SwiftUI
- 2019.09 Learn RxSwift From This Production App
- 2019.08 Simplifying RxSwift code: some different approaches of creating VMs, refers to ReactorKit in the end.
- 2019.05 RxSwift and Production-Level Code Takes GitHub Search from the RxSwift repository and refactors with a number of interesting techniques
- 2019.02 Modeling Your View Models as Functions - also check related videos from Stephen Celis and Danny Hertz.
- 2019.02 ⭐️ Anatomy of an RxSwift View Model (read the comments!)
- 2018.11 Danny Hertz - From Sketch to Xcode: Building Functional Reactive View Models from the Ground Up 30’ video, taken from Modeling Your View Models as Functions. Comes with a gist and example project.
- 2018.03 The Binder Architecture is a declarative architecture for iOS development inspired by MVVM and VIPER. It is an attempt to take the best ideas of MVVM and VIPER and implement them without the boilerplate code that the two architectures, especially the latter, suffer from
- 2017.09 ⭐️ RxSwift + MVVM: how to feed ViewModels Converting ViewModel inputs to outputs, with and without Subjects. Refers to the problem of having cells where the view is lazy loaded, thus not ready for the view model.
- 2017.06 Taming Great Complexity: MVVM, Coordinators and RxSwift
VIPER
Redux
- 2021.07 Pure Swift state management pattern (links to gist - interesting comments)
Coordinators / Routing
- 2022.08 FlowStacks Coordinator pattern in SwiftUI
- 2022.08 TCACoordinators The coordinator pattern in the Composable Architecture
- 2021.10 Decoupling Concrete Coordinators From Your Navigation System in iOS
- 2021.09 RxMyCoordinator by Daniel Tartaglia
- 2020.04 Coordinator pattern in iOS 13 world
- 2020.03 The Navigator - Another twist to iOS navigations
- 2020.02 XCoordinator on GitHub and accompanying article
- 2020.01 Using Type Erasure to Build a Dependency Injecting Routing Framework in Swift
- 2019.12 Routing for iOS: universal navigation without rewriting the app
- 2019.06 How to implement Coordinator pattern with RxSwift
- 2019.03 Navigation Problem and Controller Hierarchies challenge the need for coordinators, describing other “pure” UIKit alternatives.
- 2019.02 Advanced coordinators in iOS
- 2018.04 The C in MVVM-C.
- 2017.05 MVC-C · Injecting Coordinator pattern in UIKit. Uses the
UIResponder
chain and associated objects to achieve communication among coordinators. Another article from the same author. - 2017.01 Coordinators Essential tutorial: part I & part II. Lengthy and more advanced, comes with example project
- 2016.12 An iOS Coordinator Pattern. Uses a (not very nice)
Services
struct and comes with Github example - 2016.07 The Coordinator Pattern. Simple implementation with an example gist. Good starting point.
- 2016.02 Swift - Coordinators. Starts even before setting the window’s
rootViewController
- 2016.01 Navigation coordinators Here’s the problem: while this works great so long as the user keeps moving forward through our onboarding flow, what would happen if they tapped the navigation controller’s back button? (more links about “back” in this issue).
- 2015.10 Coordinators Redux