View Full Version : need advice on large app
18 Jan 2012, 3:46 PM
We are planning a large mcv sencha touch 2 app but need some advice on dynamic loading of models,stores and views.
Our app may have more than 100 views, stores and models consisting of lists,forms and html panels.
Can we load these files dynamically so our app is small on initial load and only loads what the user wants to use. No point loading over 200 files when the user just wants to fill out 1 form.
19 Jan 2012, 7:04 AM
So at the end of building an MVC app you should go through a build process with the SDK Tools that will build all your application classes and ST2 widgets into a single JS file. You will then load a CSS file, sencha-touch.js fie and app-all.js file. 100 classes isn't really that large, it's dependent how much code and how optimized you have made things that will be the factor.
Plus carrier signal is a huge part of it also. If they are slow then it doesn't really matter how you are loading things.
26 Jan 2012, 3:46 AM
Not tried it myself, but came across it when reading through the Controllers guide in the docs:
If you are using routes (makes a lot of sense imho), then you can use "Before Filters" to load additional classes that are only needed for specific features (routes/urls).
26 Jan 2012, 10:02 PM
Just FYI PR4 shipped with some serious issues with before filters - I'll get those fixed for the next release
Powered by vBulletin® Version 4.2.3 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.