cordova delete cache

Solutions on MaxInterview for cordova delete cache by the best coders in the world

showing results for - "cordova delete cache"
Gwyneth
26 Apr 2018
1// download this plugin. it reset cache on internal browser
2cordova plugin add https://github.com/moderna/cordova-plugin-cache.git
3
4// use this function in index.js or on main html
5document.addEventListener('deviceready', onDeviceReady);
6function onDeviceReady()
7{
8    var success = function(status) {
9        alert('Message: ' + status);
10    }
11
12    var error = function(status) {
13        alert('Error: ' + status);
14    }
15
16    window.cache.clear( success, error );
17}
Irene
03 Jun 2020
1// download this plugin. it reset cache on internal browser
2cordova plugin add cordova-plugin-cache-clear
3
4// use this function in index.js or on main html
5document.addEventListener('deviceready', function() {
6    var success = function(status) {
7        alert('Message: ' + status);
8    };
9    var error = function(status) {
10        alert('Error: ' + status);
11    };
12    window.CacheClear(success, error);
13});