My Cordova+JQM application has multiple templates (across sub-pages and multiple HTML documents) which are filled with data requested using AJAX. My issue is, my application's size increases each time I load the data in my template, doesn't matter if I have opened it before. And the app's details do not show an increase in Cache, but in Data. The cache is minimum, like a few kbs, but Data goes in MBs.
I have not enabled data-dom-cache
of JQM. I even tried to call a function to empty the DOM data before leaving the template(that is from one HTML file to another) like this:
$( document ).on( "pagecontainerbeforehide", function() {
console.log("gonna leave");
$("#page-container").empty();
} );
And it didn't work. In fact, I am not able to call any event while leaving (going to another HTML document).