Hey people,
I hope this isn't against the rules but I already asked in the Ktor channel, but I thought there might be some people here which would know some general information regarding KMM framework sizes.
So we started to use KMM with Ktor in production in our company and we noticed something strange. I just wanted to make sure if this is expected or if we are doing something wrong:
So basically adding just the Ktor Darwin engine to the iOS KMM module without the Ktor library inside the common code (and even when adding the Ktor core library in the common code, it almost doesn't increase the framework size at all) and without any code using Ktor, the binary size of the exported XCFramework binary file increases by 2.7MB.
Now know that XCode does slight optimisations afterwards to the framework file but even after those the KMM library just with the Darwin engine increases the size of our iOS application significantly, especially compared to the previous native Networking code of the app.
I was wondering if this is expected behaviour and everybody is encountering this or if maybe something is configured wrong on our side in the build set.
I already posted this question on Reddit if some of you are wondering but didn't get a lot of feedback. We really would like to keep KMM and Ktor as it really feels nice but we also want to support App Clips on iOS which imposes these App size constrains on us.