Swiftpack.co - radianttap/Coordinator as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
radianttap/Coordinator example-v1
Implementation of Coordinators app design pattern.
⭐️ 656
🕓 28 weeks ago
iOS tvOS
.package(url: "https://github.com/radianttap/Coordinator.git", from: "example-v1")

platforms: iOS|tvOS SwiftPM ready Carthage compatible CocoaPods compatible


Implementation of Coordinator design pattern. It is the application architecture pattern for iOS, carefully designed to fit into UIKit; so much it could easily be UICoordinator.

Since this is core architectural pattern, it’s not possible to explain its usage with one or two clever lines of code. Give it a day or two; analyze and play around. I’m pretty sure you’ll find it worthy of your time and future projects.



My preferred method is to integrate Coordinator into the project manually. Just drag Coordinator folder into your project — it‘s only a handful of files.

If you prefer to use dependency managers, see below. Releases are tagged with Semantic Versioning in mind.

Swift Package Manager

Ready, just add this repo URL as Package. I recommend to link with master branch, not with specific version.


CocoaPods is a dependency manager for Cocoa projects. For usage and installation instructions, visit their website. To integrate Coordinator into your Xcode project using CocoaPods, specify it in your Podfile:

pod 'Coordinator', 	:git => 'https://github.com/radianttap/Coordinator.git'

You must use direct link through :git since CocoaPods central repository contains a framework of the same name.[^1]

Setting up with Carthage

Carthage is a decentralized dependency manager that automates the process of adding frameworks to your Cocoa application.

You can install Carthage with Homebrew using the following command:

$ brew update
$ brew install carthage

To integrate Coordinator into your Xcode project using Carthage, specify it in your Cartfile:

github "radianttap/Coordinator"


The why and how and...

Further reading

On my blog: Coordinator: the missing pattern in UIKit

Rough history of development, also on my blog. I did not come up with the library all at once, it was a gradual process as all good things are.

Soroush Khanlou: Coordinators Redux

Andrey Panov: Coordinators Essential tutorial

Matthew Wyskiel: Protocol-Oriented App Coordinators in Swift

Coordinators are fairly old pattern but it was Soroush who brought them under iOS developer spotlight in 2015. My library follows the core idea but employs a different implementation.

Bill Dudney, WWDC 2014, session 224: Core iOS Application Architectural Patterns

Andy Matuschak & Colin Barrett, WWDC 2014, session 229: Advanced iOS Application Architecture and Patterns

I file these two talks under essential education for any iOS developer. While not directly associated with Coordinator pattern, you should still carefully watch and listen to understand what it means to “fit inside iOS SDK”.


MIT, as usual.

Give back

If you found this code useful, please consider buying me a coffee or two. ☕️😋

[^1]: That framework seems long abandoned and my requests to remove it and thus allow me to publish mine were unsuccessful.


Stars: 656
Last commit: 2 weeks ago

Ad: Job Offers

iOS Software Engineer @ Perry Street Software
Perry Street Software is Jack’d and SCRUFF. We are two of the world’s largest gay, bi, trans and queer social dating apps on iOS and Android. Our brands reach more than 20 million members worldwide so members can connect, meet and express themselves on a platform that prioritizes privacy and security. We invest heavily into SwiftUI and using Swift Packages to modularize the codebase.

Submit a free job ad (while I'm testing this). The analytics numbers for this website are here.

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics