{ "id": "173747", "key": "AC-6285", "fields": { "issuetype": { "id": "4", "description": "An improvement or enhancement to an existing feature or task.", "name": "Improvement", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "7", "description": "", "name": "Invalid" }, "resolutiondate": "2019-06-18T11:23:36.000+0000", "created": "2019-06-11T20:07:52.000+0000", "labels": [], "versions": [], "issuelinks": [], "assignee": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2019-06-18T11:23:36.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "I made a very simple app, a two .js, with 5 views in 2 webView. It has practically no images, yet once the APK is made the weight reaches 14mb, on Apple 8Mb.\r\nIs there anything you can do to lighten it?", "attachment": [], "flagged": false, "summary": "Very heavy app!", "creator": { "name": "gtassistro", "key": "gtassistro", "displayName": "Giorgio Tassistro", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "gtassistro", "key": "gtassistro", "displayName": "Giorgio Tassistro", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "449006", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "body": "Hello, You should follow the guide in this blog post https://devblog.axway.com/mobile-apps/optimising-titanium-app-file-sizes/. This will help you reduce the size of the APK. Thanks. ", "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2019-06-11T21:51:44.000+0000", "updated": "2019-06-11T21:51:44.000+0000" }, { "id": "449010", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "When you build a \"production\" APK, we remove the x86 architecture (mostly intended for the Android emulator) by default which will lower the APK size by about a third. It still won't be as small as an iOS app build, but it will be smaller than a test/development build.", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-06-11T22:55:21.000+0000", "updated": "2019-06-11T22:55:21.000+0000" }, { "id": "449022", "author": { "name": "gtassistro", "key": "gtassistro", "displayName": "Giorgio Tassistro", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Ok ... I do some research ...\r\nBut how much \"weight\" axway, for an app (of default) ?\r\nIf I don't use \"Alloy\" and i use only titanium, how much space do I save?\r\nFor example, I do not use maps, geolocation, camera, and more. \r\nCan I exclude some modules to be lighter ?", "updateAuthor": { "name": "gtassistro", "key": "gtassistro", "displayName": "Giorgio Tassistro", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-06-12T14:15:39.000+0000", "updated": "2019-06-12T14:15:39.000+0000" }, { "id": "449025", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "The Google V8 JavaScript runtime C/C++ library we are embedding within the APK is what's adding significant \"weight\" to it. This library is needed to execute the project's JS files. And since it's a C/C++ library, we have to build it for each architecture such as ARMv7, ARM64, and x86. That's why removing the x86 version of that library via a \"production\" build lowers the APK size so significantly.\r\n\r\nYou really can't make it any \"lighter\". Titanium by default already excludes other large libraries by default... such as anything that requires the Google Play Services like \"ti.map\".\r\n\r\nSide Note:\r\nOn iOS, Titanium uses Apple's JavaScriptCore library built into the operating system. Unfortunately, the Android OS does not offer a built-in JavaScript runtime for us to use and we're therefore forced to include a runtime library within the app.", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-06-12T16:47:01.000+0000", "updated": "2019-06-12T16:47:01.000+0000" }, { "id": "449028", "author": { "name": "gtassistro", "key": "gtassistro", "displayName": "Giorgio Tassistro", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Joshua,\r\nall clear, thanks for the complete answer. I understand why on iOs it is 40% lighter.\r\n\r\n", "updateAuthor": { "name": "gtassistro", "key": "gtassistro", "displayName": "Giorgio Tassistro", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-06-12T19:15:16.000+0000", "updated": "2019-06-12T19:15:16.000+0000" }, { "id": "449030", "author": { "name": "michael", "key": "michael", "displayName": "Michael Gangolf", "active": true, "timeZone": "Europe/Berlin" }, "body": "[~gtassistro] you can do some crazy hacks with a native app to reduce the size: https://fractalwrench.co.uk/posts/playing-apk-golf-how-low-can-an-android-app-go/ e.g. changing the spp name, remove items from the manifest or even remove fields from the keystore file :-) But I'm not sure if that is really practical but it's a nice read!", "updateAuthor": { "name": "michael", "key": "michael", "displayName": "Michael Gangolf", "active": true, "timeZone": "Europe/Berlin" }, "created": "2019-06-12T20:07:05.000+0000", "updated": "2019-06-12T20:07:05.000+0000" }, { "id": "449151", "author": { "name": "topener", "key": "topener", "displayName": "Rene Pot", "active": true, "timeZone": "Europe/Berlin" }, "body": "For Android you could compile an APK for each architecture and upload them separately to the play store using the {{}} tiapp property. https://wiki.appcelerator.org/display/guides2/tiapp.xml+and+timodule.xml+Reference#tiapp.xmlandtimodule.xmlReference-abi\r\n\r\nOn iOS you can make the app smaller by removing all splash screens and sticking with launch storyboard https://wiki.appcelerator.org/display/guides2/iOS+Launch+Files#iOSLaunchFiles-OptionA:UsethebuiltinStoryboard\r\n\r\nHope that helps even more!", "updateAuthor": { "name": "topener", "key": "topener", "displayName": "Rene Pot", "active": true, "timeZone": "Europe/Berlin" }, "created": "2019-06-18T11:23:23.000+0000", "updated": "2019-06-18T11:23:23.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }