In some cases I need to reinitialize my Sencha Touch app. Till now I just used location.reload()to do this. However this is really bad for the user experience as the whole HTML page, JS and CSS will be reloaded, too.So I'm looking for an easy and clean way to reset and reinitialize my app without reloading the whole page.
I tried to do something like Ext.Viewport.removeAll(true, true) to remove all view components from the viewport. But this results in some errors, when you masked the viewport before or if you showed some dialogs before. Sencha keeps some references to objects created while masking the view or showing a dialog, that won't be present any more after removing all components from the viewport:
Ext.Msg.alert()
Ext.Viewport.removeAll(true,true)
Ext.Msg.alert()// => will raise `TypeError: Cannot read property 'dom' of null`How do you reinitialize your app without reloading the whole page? Is there any way to do it "the nice" way?