Scaling Slack’s Mobile Codebases: Modularization
Article Summary
Slack's mobile codebase was slowing teams down. Their solution? Break the monolith into hundreds of independent modules.
Slack's engineering team documented their multi-year Duplo project, specifically the modularization phase that transformed how their iOS and Android teams build and ship features. This is a deep dive into the architectural decisions, tooling choices, and organizational strategies that made it work.
Key Takeaways
- Adopted Bazel for iOS, making module creation simple after XCode's painful process
- Android switched from nested Dagger graphs to Square's Anvil library, cutting boilerplate significantly
- Configuration caching alone saved 20-45 seconds on successive Android builds
- Three module types (Feature, Service, Library) with Interface/Implementation splits prevent tight coupling
- Involved pillar leads from each product team instead of isolating work
Critical Insight
Modularization proved to be the highest-impact component of Slack's mobile infrastructure initiative, enabling faster builds and autonomous team development.