开发者

How to optimize the size of Titanium based iPhone App?

开发者 https://www.devze.com 2023-01-25 11:13 出处:网络
I have created a iPhone App using the Titanium Framework. The app has totally 4 开发者_StackOverflow中文版screens. I do not use any database at all. But my application size seems to be around 5.7 MB.

I have created a iPhone App using the Titanium Framework. The app has totally 4 开发者_StackOverflow中文版screens. I do not use any database at all. But my application size seems to be around 5.7 MB. Is there any way to reduce the size of the application?


Using code generators always leads to code bloat, as the framework will contribute a number of libraries it uses.

I'm sure if you wrote the app in straight Obj-C it would be much, much smaller.


I'm not sure if it exists a way to reduce your executable's size, but of course, as @exception said, when you use such frameworks, that's quite obvious you'll get a "larger" executable.

The question I'd ask you is the following: do you really need Titanium?

As you already said, you just have 4 screens (I guess they are 4 .html). Why do you use this SDK?

Portability? Well, then it's ok. Remind that your application can be viewed on Android, iOS, Desktop and so on as if it was installed on just one device :)

You should start with the assumption that if you want A, B and C maybe you can't get D. Think about what you consider more important for you: executable's size or portability/others?


Without echoing the answers above that using these sort of frameworks inevitably leads to code bloat

Have you made sure any graphical assets you have included in the application have been optimised, the iOS sdk itself will optimize pngs with pngcrush for you, but you can probably reduce these further without too much loss of quality if download size is a more important issue

0

精彩评论

暂无评论...
验证码 换一张
取 消