Completely offline app - images in carousel
I need to write a completely offline app, which will be packaged for iOS.
It's quite simple, just a catalogue really, with images and text.
Is it possible to drive the carousel with images stored locally as resources which are bundled with the app?
Absolutely. Just have the images in the app's directory, and add a reference to them in app.json. This will ensure they are copied when you build the app using sencha command.
Wow, that was quick, thank you
Do I have to access the images via the LocalStorage proxy or can I just have a direct reference to them somehow?
when you include the images in the app (you might do this, for instance, by using the Ext.Img class and setting the src) just use a relative file path from the root of the app, to where you have the images. So if you have them at resources/images/carousel/img.jpg you'd put as the src of the Ext.Img exactly the same ("resources/images/carousel/img.jpg").
Tags for this Thread