How to Efficiently Manage Resources in an iOS Multi-Framework Environment
Key point
Kakaopay introduced a resource module and standardized usage patterns to manage app size in a multi-module environment.
Details
In large-scale multi-module projects, resource management is difficult, creating a risk of app size increasing sharply. In fact, Kakaopay experienced an issue where a specific module's size increased by 10MB due to improper use of image formats.
To solve this, they built a resource module that manages resources in one place. Through this, they achieved the result of removing 146 duplicate resources across the project and optimizing app size.
They also standardized how resources are used, taking into account environments shared across multiple apps. By introducing the PayResourceSupports protocol, they provided a separate access path called .pay that doesn't conflict with the naming of existing UIImage or UIColor, improving maintainability.
When using the resource module, there is a caution that since resource files exist not in the main bundle but within the corresponding resource module bundle, the bundle must be explicitly specified.
This summary was generated automatically by AI. Check the original for the author's claims and context. Copyright belongs to the original author.
Our guide explains how the AI works. Report summary errors, attribution issues, or removal requests via Contact.