0

I have build application using sencha touch, its all working fine except initial issue of initial loding time. I have make its native app. using phonegap, have build its jsb3 file and app-all.js using that. but its nothing to do with sencha-touch.js which has original size of about 2.4 M.B. and its minified is also about 600 K.b. which is very large for mobile/tablet.

Is there anything like we can use sencha.js for only those component we are using in app ? or anyother way to reduce size or initial loading time?

Please provide me solution for this

Sagar Modi
  • 770
  • 2
  • 7
  • 29
  • Check out similar performance issues discussed here ... http://stackoverflow.com/questions/10338020/sencha-touch-2-android-performance & http://stackoverflow.com/questions/10085637/phonegap-1-4-wrapping-sencha-touch-2-x-what-about-performance/10085756#10085756 – Saurabh Gokhale May 07 '12 at 09:02
  • Thanks for you reply, i already try to follow as per your answer keeping my DOM as minimal as possible, dynamically handling viewes but i can't do much with sencha-touch.js except minified and compress and its creating initial loading problem – Sagar Modi May 07 '12 at 09:12
  • anyone can help me ?? still not found solution for this – Sagar Modi May 11 '12 at 07:16

1 Answers1

0

You can build a native application with Sencha SDK Tools.

If you have structured your project properly, you can use the following command to build your native application. This will also shrink your javascript size:

C:\wamp\www\SenchaApp>sencha app build -e native -d pkg/native -a archive
[INFO] Deploying your application to C:\wamp\www\SenchaApp\pkg\native
[INFO] Copied sdk/sencha-touch.js
[INFO] Copied app.js
[INFO] Copied resources/css/app.css
[INFO] Copied resources/images
[INFO] Copied resources/icons
[INFO] Copied resources/loading
[INFO] Copied resources/data
[INFO] Resolving your application dependencies...
[INFO] Found 18 dependencies. Concatenating all into app.js...
[INFO] Processed sdk/sencha-touch.js
[INFO] Minifying sdk/sencha-touch.js
[INFO] Processed app.js
[INFO] Minifying app.js
[INFO] Minifying resources/css/app.css
[INFO] Minified app.js
[INFO] Minified sdk/sencha-touch.js
[INFO] Minified resources/css/app.css
[INFO] Generated app.json
[INFO] Embedded microloader into index.html
[INFO] Packaging your application as a native app...
mostar
  • 4,723
  • 2
  • 28
  • 45