OkCupid Dmitri Fuerle

OkCupid: Migrating Your App to Swift Packages

Original post Migrating Your App to Swift Packages

Article Summary

Dmitri Fuerle from OkCupid reveals how their team cut clean build times to under a minute by modularizing their iOS codebase. The secret? Swift Package Manager in a monorepo setup.

As iOS apps grow, they become harder to maintain and slower to compile. OkCupid's engineering team tackled this by breaking their monolithic app into Swift Package modules. This tutorial walks through the practical steps of setting up your first local Swift Package within your existing project.

Key Takeaways

Critical Insight

Breaking iOS apps into Swift Package modules dramatically improves compile times and code maintainability without requiring separate repositories.

Continue reading

What This Article Covers

Problem

As OkCupid's iOS app grew, its codebase became disorganized and hard to maintain. The lack of good architecture made it increasingly difficult to manage.

Solution

Dmitri Fuerle's team set up Swift Package Manager using a monorepo structure. They organized packages in a Modules folder within their existing Git repository and used Public and Internal folders to control access.

Impact

Developers could now test individual modules in about 10 seconds without rebuilding the whole app. This modularization also made independent compilation possible.

Part 2 of this series covers how to handle communication between modules as your package adoption scales across the team.

This page summarizes “Migrating Your App to Swift Packages” by OkCupid, published Apr 5, 2021. All credit for the original work goes to the authors.

Read the original on tech.okcupid.com (opens in new tab)

AI tools for iOS

Browse all AI tools →